home *** CD-ROM | disk | FTP | other *** search
/ Windows News 2005 February / WN_129_CD.iso / Windows / Extensions Firefox / Bookmark Links Checker / BookmarkLinksChecker-0.6.8-Fr.xpi next >
PKZip Archive  |  2004-12-10  |  93.2 KB

open in: MacOS 8.1     |     Win98     |     DOS

browse contents    |     view JSON data     |     view as text


This file was processed as: PKZip Archive (archive/zip).

ConfidenceProgramDetectionMatch TypeSupport
100% dexvert PKZip Archive (archive/zip) magic Supported
100% file Zip archive data, made by v2.0, extract using at least v1.0, last modified, last modified Sun, Oct 19 2004 08:52:42, uncompressed size 0, method=store default
99% file Zip archive, with extra data prepended default
98% file data default
46% TrID Sweet Home 3D design (generic) default (weak)
35% TrID Mozilla Firefox browser extension default (weak)
17% TrID ZIP compressed archive default
100% dexmagic PrintFox/Pagefox WEAK default
100% siegfried x-fmt/263 ZIP Format default
100% lsar Zip default
100% gt2 ZIP Archiv gefunden (Auflistung ist deaktiviert) default
100% detectItEasy Archive: Zip(1.0)[100.0%,2 files,1 dir] default
100% binwalkID Zip archive data, at least v1.0 to extract, name: chrome/ default
100% xdgMime application/zip default



hex view
+--------+-------------------------+-------------------------+--------+--------+
|00000000| 50 4b 03 04 0a 00 00 00 | 00 00 95 46 53 31 00 00 |PK......|...FS1..|
|00000010| 00 00 00 00 00 00 00 00 | 00 00 07 00 00 00 63 68 |........|......ch|
|00000020| 72 6f 6d 65 2f 50 4b 03 | 04 0a 00 00 00 00 00 8d |rome/PK.|........|
|00000030| 46 53 31 bc 69 2c c0 52 | 6d 01 00 52 6d 01 00 16 |FS1.i,.R|m..Rm...|
|00000040| 00 00 00 63 68 72 6f 6d | 65 2f 6c 69 6e 6b 63 68 |...chrom|e/linkch|
|00000050| 65 63 6b 65 72 2e 6a 61 | 72 50 4b 03 04 0a 00 00 |ecker.ja|rPK.....|
|00000060| 00 00 00 c8 44 53 31 00 | 00 00 00 00 00 00 00 00 |....DS1.|........|
|00000070| 00 00 00 08 00 00 00 63 | 6f 6e 74 65 6e 74 2f 50 |.......c|ontent/P|
|00000080| 4b 03 04 0a 00 00 00 00 | 00 c8 44 53 31 00 00 00 |K.......|..DS1...|
|00000090| 00 00 00 00 00 00 00 00 | 00 14 00 00 00 63 6f 6e |........|.....con|
|000000a0| 74 65 6e 74 2f 6c 69 6e | 6b 63 68 65 63 6b 65 72 |tent/lin|kchecker|
|000000b0| 2f 50 4b 03 04 0a 00 00 | 00 00 00 c8 44 53 31 00 |/PK.....|....DS1.|
|000000c0| 00 00 00 00 00 00 00 00 | 00 00 00 1d 00 00 00 63 |........|.......c|
|000000d0| 6f 6e 74 65 6e 74 2f 6c | 69 6e 6b 63 68 65 63 6b |ontent/l|inkcheck|
|000000e0| 65 72 2f 62 69 6e 64 69 | 6e 67 73 2f 50 4b 03 04 |er/bindi|ngs/PK..|
|000000f0| 0a 00 00 00 00 00 10 4f | f4 30 fe 05 d7 ca 97 8f |.......O|.0......|
|00000100| 00 00 97 8f 00 00 2e 00 | 00 00 63 6f 6e 74 65 6e |........|..conten|
|00000110| 74 2f 6c 69 6e 6b 63 68 | 65 63 6b 65 72 2f 62 69 |t/linkch|ecker/bi|
|00000120| 6e 64 69 6e 67 73 2f 62 | 6f 6f 6b 6d 61 72 6b 73 |ndings/b|ookmarks|
|00000130| 54 72 65 65 2e 78 6d 6c | 3c 3f 78 6d 6c 20 76 65 |Tree.xml|<?xml ve|
|00000140| 72 73 69 6f 6e 3d 22 31 | 2e 30 22 3f 3e 20 20 0d |rsion="1|.0"?> .|
|00000150| 0a 0d 0a 0d 0a 3c 21 44 | 4f 43 54 59 50 45 20 77 |.....<!D|OCTYPE w|
|00000160| 69 6e 64 6f 77 20 5b 0d | 0a 20 20 3c 21 45 4e 54 |indow [.|. <!ENT|
|00000170| 49 54 59 20 25 20 62 6f | 6f 6b 6d 61 72 6b 73 44 |ITY % bo|okmarksD|
|00000180| 54 44 20 53 59 53 54 45 | 4d 20 22 63 68 72 6f 6d |TD SYSTE|M "chrom|
|00000190| 65 3a 2f 2f 62 72 6f 77 | 73 65 72 2f 6c 6f 63 61 |e://brow|ser/loca|
|000001a0| 6c 65 2f 62 6f 6f 6b 6d | 61 72 6b 73 2f 62 6f 6f |le/bookm|arks/boo|
|000001b0| 6b 6d 61 72 6b 73 2e 64 | 74 64 22 20 3e 0d 0a 20 |kmarks.d|td" >.. |
|000001c0| 20 25 62 6f 6f 6b 6d 61 | 72 6b 73 44 54 44 3b 0d | %bookma|rksDTD;.|
|000001d0| 0a 20 20 3c 21 45 4e 54 | 49 54 59 20 25 20 6c 69 |. <!ENT|ITY % li|
|000001e0| 6e 6b 63 68 65 63 6b 65 | 72 44 54 44 20 53 59 53 |nkchecke|rDTD SYS|
|000001f0| 54 45 4d 20 22 63 68 72 | 6f 6d 65 3a 2f 2f 6c 69 |TEM "chr|ome://li|
|00000200| 6e 6b 63 68 65 63 6b 65 | 72 2f 6c 6f 63 61 6c 65 |nkchecke|r/locale|
|00000210| 2f 6c 69 6e 6b 63 68 65 | 63 6b 65 72 2e 64 74 64 |/linkche|cker.dtd|
|00000220| 22 20 3e 0d 0a 20 20 25 | 6c 69 6e 6b 63 68 65 63 |" >.. %|linkchec|
|00000230| 6b 65 72 44 54 44 3b 0d | 0a 5d 3e 0d 0a 0d 0a 3c |kerDTD;.|.]>....<|
|00000240| 62 69 6e 64 69 6e 67 73 | 20 69 64 3d 22 62 6f 6f |bindings| id="boo|
|00000250| 6b 6d 61 72 6b 73 42 69 | 6e 64 69 6e 67 73 22 20 |kmarksBi|ndings" |
|00000260| 0d 0a 20 20 20 20 20 20 | 20 20 20 20 78 6d 6c 6e |.. | xmln|
|00000270| 73 3d 22 68 74 74 70 3a | 2f 2f 77 77 77 2e 6d 6f |s="http:|//www.mo|
|00000280| 7a 69 6c 6c 61 2e 6f 72 | 67 2f 78 62 6c 22 20 0d |zilla.or|g/xbl" .|
|00000290| 0a 20 20 20 20 20 20 20 | 20 20 20 78 6d 6c 6e 73 |. | xmlns|
|000002a0| 3a 78 75 6c 3d 22 68 74 | 74 70 3a 2f 2f 77 77 77 |:xul="ht|tp://www|
|000002b0| 2e 6d 6f 7a 69 6c 6c 61 | 2e 6f 72 67 2f 6b 65 79 |.mozilla|.org/key|
|000002c0| 6d 61 73 74 65 72 2f 67 | 61 74 65 6b 65 65 70 65 |master/g|atekeepe|
|000002d0| 72 2f 74 68 65 72 65 2e | 69 73 2e 6f 6e 6c 79 2e |r/there.|is.only.|
|000002e0| 78 75 6c 22 20 0d 0a 20 | 20 20 20 20 20 20 20 20 |xul" .. | |
|000002f0| 20 78 6d 6c 6e 73 3a 72 | 64 66 3d 22 68 74 74 70 | xmlns:r|df="http|
|00000300| 3a 2f 2f 77 77 77 2e 77 | 33 2e 6f 72 67 2f 31 39 |://www.w|3.org/19|
|00000310| 39 39 2f 30 32 2f 32 32 | 2d 72 64 66 2d 73 79 6e |99/02/22|-rdf-syn|
|00000320| 74 61 78 2d 6e 73 23 22 | 0d 0a 20 20 20 20 20 20 |tax-ns#"|.. |
|00000330| 20 20 20 20 78 6d 6c 6e | 73 3a 78 62 6c 3d 22 68 | xmln|s:xbl="h|
|00000340| 74 74 70 3a 2f 2f 77 77 | 77 2e 6d 6f 7a 69 6c 6c |ttp://ww|w.mozill|
|00000350| 61 2e 6f 72 67 2f 78 62 | 6c 22 3e 0d 0a 0d 0a 20 |a.org/xb|l">.... |
|00000360| 20 3c 62 69 6e 64 69 6e | 67 20 69 64 3d 22 62 6f | <bindin|g id="bo|
|00000370| 6f 6b 6d 61 72 6b 73 2d | 74 72 65 65 22 3e 0d 0a |okmarks-|tree">..|
|00000380| 20 20 20 20 3c 69 6d 70 | 6c 65 6d 65 6e 74 61 74 | <imp|lementat|
|00000390| 69 6f 6e 3e 0d 0a 20 20 | 20 20 20 20 3c 63 6f 6e |ion>.. | <con|
|000003a0| 73 74 72 75 63 74 6f 72 | 3e 3c 21 5b 43 44 41 54 |structor|><![CDAT|
|000003b0| 41 5b 0d 0a 20 20 20 20 | 20 20 20 20 2f 2f 20 54 |A[.. | // T|
|000003c0| 68 69 73 20 66 75 6e 63 | 74 69 6f 6e 20 6f 6e 6c |his func|tion onl|
|000003d0| 79 20 72 65 61 64 73 20 | 69 6e 20 74 68 65 20 62 |y reads |in the b|
|000003e0| 6f 6f 6b 6d 61 72 6b 73 | 20 66 72 6f 6d 20 64 69 |ookmarks| from di|
|000003f0| 73 6b 20 69 66 20 74 68 | 65 79 20 68 61 76 65 20 |sk if th|ey have |
|00000400| 6e 6f 74 20 61 6c 72 65 | 61 64 79 20 62 65 65 6e |not alre|ady been|
|00000410| 20 72 65 61 64 2e 0d 0a | 20 20 20 20 20 20 20 20 | read...| |
|00000420| 69 6e 69 74 53 65 72 76 | 69 63 65 73 28 29 3b 0d |initServ|ices();.|
|00000430| 0a 20 20 20 20 20 20 20 | 20 69 6e 69 74 42 4d 53 |. | initBMS|
|00000440| 65 72 76 69 63 65 28 29 | 3b 0d 0a 0d 0a 20 20 20 |ervice()|;.... |
|00000450| 20 20 20 20 20 42 4d 53 | 56 43 2e 72 65 61 64 42 | BMS|VC.readB|
|00000460| 6f 6f 6b 6d 61 72 6b 73 | 28 29 3b 0d 0a 20 20 20 |ookmarks|();.. |
|00000470| 20 20 20 20 20 0d 0a 20 | 20 20 20 20 20 20 20 2f | .. | /|
|00000480| 2f 20 57 65 20 69 6d 70 | 6c 65 6d 65 6e 74 20 6e |/ We imp|lement n|
|00000490| 73 49 43 6f 6e 74 72 6f | 6c 6c 65 72 0d 0a 20 20 |sIContro|ller.. |
|000004a0| 20 20 20 20 20 20 74 68 | 69 73 2e 74 72 65 65 2e | th|is.tree.|
|000004b0| 63 6f 6e 74 72 6f 6c 6c | 65 72 73 2e 61 70 70 65 |controll|ers.appe|
|000004c0| 6e 64 43 6f 6e 74 72 6f | 6c 6c 65 72 28 74 68 69 |ndContro|ller(thi|
|000004d0| 73 2e 63 6f 6e 74 72 6f | 6c 6c 65 72 29 3b 0d 0a |s.contro|ller);..|
|000004e0| 20 20 20 20 20 20 20 20 | 76 61 72 20 6f 6c 62 20 | |var olb |
|000004f0| 3d 20 64 6f 63 75 6d 65 | 6e 74 2e 67 65 74 41 6e |= docume|nt.getAn|
|00000500| 6f 6e 79 6d 6f 75 73 45 | 6c 65 6d 65 6e 74 42 79 |onymousE|lementBy|
|00000510| 41 74 74 72 69 62 75 74 | 65 28 74 68 69 73 2c 20 |Attribut|e(this, |
|00000520| 22 61 6e 6f 6e 69 64 22 | 2c 20 22 62 6f 6f 6b 6d |"anonid"|, "bookm|
|00000530| 61 72 6b 73 2d 74 72 65 | 65 22 29 3b 0d 0a 20 20 |arks-tre|e");.. |
|00000540| 20 20 20 20 20 20 6f 6c | 62 20 3d 20 6f 6c 62 2e | ol|b = olb.|
|00000550| 62 75 69 6c 64 65 72 2e | 51 75 65 72 79 49 6e 74 |builder.|QueryInt|
|00000560| 65 72 66 61 63 65 28 43 | 6f 6d 70 6f 6e 65 6e 74 |erface(C|omponent|
|00000570| 73 2e 69 6e 74 65 72 66 | 61 63 65 73 2e 6e 73 49 |s.interf|aces.nsI|
|00000580| 58 55 4c 54 72 65 65 42 | 75 69 6c 64 65 72 29 3b |XULTreeB|uilder);|
|00000590| 0d 0a 20 20 20 20 20 20 | 20 20 6f 6c 62 2e 61 64 |.. | olb.ad|
|000005a0| 64 4f 62 73 65 72 76 65 | 72 28 74 68 69 73 2e 62 |dObserve|r(this.b|
|000005b0| 75 69 6c 64 65 72 4f 62 | 73 65 72 76 65 72 29 3b |uilderOb|server);|
|000005c0| 0d 0a 0d 0a 20 20 20 20 | 20 20 20 20 2f 2f 20 4c |.... | // L|
|000005d0| 6f 61 64 20 63 6f 6c 75 | 6d 6e 20 73 65 74 74 69 |oad colu|mn setti|
|000005e0| 6e 67 73 20 66 72 6f 6d | 20 70 65 72 73 69 73 74 |ngs from| persist|
|000005f0| 65 64 20 61 74 74 72 69 | 62 75 74 65 0d 0a 20 20 |ed attri|bute.. |
|00000600| 20 20 20 20 20 20 76 61 | 72 20 63 6f 6c 69 6e 66 | va|r colinf|
|00000610| 6f 73 74 72 20 3d 20 74 | 68 69 73 2e 67 65 74 41 |ostr = t|his.getA|
|00000620| 74 74 72 69 62 75 74 65 | 28 22 63 6f 6c 69 6e 66 |ttribute|("colinf|
|00000630| 6f 22 29 3b 0d 0a 20 20 | 20 20 20 20 20 20 76 61 |o");.. | va|
|00000640| 72 20 63 6f 6c 69 6e 66 | 6f 20 3d 20 63 6f 6c 69 |r colinf|o = coli|
|00000650| 6e 66 6f 73 74 72 2e 73 | 70 6c 69 74 28 22 20 22 |nfostr.s|plit(" "|
|00000660| 29 3b 0d 0a 20 20 20 20 | 20 20 20 20 66 6f 72 20 |);.. | for |
|00000670| 28 76 61 72 20 69 20 3d | 20 30 3b 20 69 20 3c 20 |(var i =| 0; i < |
|00000680| 63 6f 6c 69 6e 66 6f 2e | 6c 65 6e 67 74 68 3b 20 |colinfo.|length; |
|00000690| 2b 2b 69 29 20 7b 0d 0a | 20 20 20 20 20 20 20 20 |++i) {..| |
|000006a0| 20 20 69 66 20 28 63 6f | 6c 69 6e 66 6f 5b 69 5d | if (co|linfo[i]|
|000006b0| 20 3d 3d 20 22 22 29 20 | 63 6f 6e 74 69 6e 75 65 | == "") |continue|
|000006c0| 3b 0d 0a 0d 0a 20 20 20 | 20 20 20 20 20 20 20 76 |;.... | v|
|000006d0| 61 72 20 71 75 65 72 79 | 6d 61 72 6b 65 72 20 3d |ar query|marker =|
|000006e0| 20 63 6f 6c 69 6e 66 6f | 5b 69 5d 2e 69 6e 64 65 | colinfo|[i].inde|
|000006f0| 78 4f 66 28 22 3f 22 29 | 3b 0d 0a 20 20 20 20 20 |xOf("?")|;.. |
|00000700| 20 20 20 20 20 76 61 72 | 20 61 6e 6f 6e 69 64 20 | var| anonid |
|00000710| 3d 20 63 6f 6c 69 6e 66 | 6f 5b 69 5d 2e 73 75 62 |= colinf|o[i].sub|
|00000720| 73 74 72 69 6e 67 28 34 | 2c 20 71 75 65 72 79 6d |string(4|, querym|
|00000730| 61 72 6b 65 72 29 3b 0d | 0a 20 20 20 20 20 20 20 |arker);.|. |
|00000740| 20 20 20 76 61 72 20 63 | 6f 6c 20 3d 20 64 6f 63 | var c|ol = doc|
|00000750| 75 6d 65 6e 74 2e 67 65 | 74 41 6e 6f 6e 79 6d 6f |ument.ge|tAnonymo|
|00000760| 75 73 45 6c 65 6d 65 6e | 74 42 79 41 74 74 72 69 |usElemen|tByAttri|
|00000770| 62 75 74 65 28 74 68 69 | 73 2c 20 22 69 64 22 2c |bute(thi|s, "id",|
|00000780| 20 61 6e 6f 6e 69 64 29 | 3b 0d 0a 0d 0a 20 20 20 | anonid)|;.... |
|00000790| 20 20 20 20 20 20 20 69 | 66 20 28 21 61 6e 6f 6e | i|f (!anon|
|000007a0| 69 64 20 7c 7c 20 21 63 | 6f 6c 29 20 62 72 65 61 |id || !c|ol) brea|
|000007b0| 6b 3b 0d 0a 0d 0a 20 20 | 20 20 20 20 20 20 20 20 |k;.... | |
|000007c0| 76 61 72 20 61 74 74 72 | 73 74 72 69 6e 67 20 3d |var attr|string =|
|000007d0| 20 63 6f 6c 69 6e 66 6f | 5b 69 5d 2e 73 75 62 73 | colinfo|[i].subs|
|000007e0| 74 72 28 71 75 65 72 79 | 6d 61 72 6b 65 72 20 2b |tr(query|marker +|
|000007f0| 20 31 29 3b 0d 0a 0d 0a | 20 20 20 20 20 20 20 20 | 1);....| |
|00000800| 20 20 76 61 72 20 61 74 | 74 72 70 61 69 72 73 20 | var at|trpairs |
|00000810| 3d 20 61 74 74 72 73 74 | 72 69 6e 67 2e 73 70 6c |= attrst|ring.spl|
|00000820| 69 74 28 22 26 22 29 3b | 0d 0a 20 20 20 20 20 20 |it("&");|.. |
|00000830| 20 20 20 20 66 6f 72 20 | 28 76 61 72 20 6a 20 3d | for |(var j =|
|00000840| 20 30 3b 20 6a 20 3c 20 | 61 74 74 72 70 61 69 72 | 0; j < |attrpair|
|00000850| 73 2e 6c 65 6e 67 74 68 | 3b 20 2b 2b 6a 29 20 7b |s.length|; ++j) {|
|00000860| 0d 0a 20 20 20 20 20 20 | 20 20 20 20 20 20 76 61 |.. | va|
|00000870| 72 20 70 61 69 72 20 3d | 20 61 74 74 72 70 61 69 |r pair =| attrpai|
|00000880| 72 73 5b 6a 5d 2e 73 70 | 6c 69 74 28 22 3d 22 29 |rs[j].sp|lit("=")|
|00000890| 3b 0d 0a 20 20 20 20 20 | 20 20 20 20 20 20 20 63 |;.. | c|
|000008a0| 6f 6c 2e 73 65 74 41 74 | 74 72 69 62 75 74 65 28 |ol.setAt|tribute(|
|000008b0| 70 61 69 72 5b 30 5d 2c | 20 70 61 69 72 5b 31 5d |pair[0],| pair[1]|
|000008c0| 29 3b 0d 0a 20 20 20 20 | 20 20 20 20 20 20 7d 0d |);.. | }.|
|000008d0| 0a 20 20 20 20 20 20 20 | 20 7d 0d 0a 20 20 20 20 |. | }.. |
|000008e0| 20 20 20 20 0d 0a 20 20 | 20 20 20 20 20 20 2f 2f | .. | //|
|000008f0| 20 4c 6f 61 64 20 73 6f | 72 74 20 64 61 74 61 20 | Load so|rt data |
|00000900| 66 72 6f 6d 20 70 72 65 | 66 65 72 65 6e 63 65 73 |from pre|ferences|
|00000910| 0d 0a 20 20 20 20 20 20 | 20 20 74 68 69 73 2e 72 |.. | this.r|
|00000920| 65 66 72 65 73 68 53 6f | 72 74 28 29 3b 0d 0a 20 |efreshSo|rt();.. |
|00000930| 20 20 20 20 20 20 20 0d | 0a 20 20 20 20 20 20 20 | .|. |
|00000940| 20 2f 2f 20 4f 62 73 65 | 72 76 65 20 66 6f 72 20 | // Obse|rve for |
|00000950| 63 68 61 6e 67 65 73 20 | 69 6e 20 73 6f 72 74 20 |changes |in sort |
|00000960| 66 72 6f 6d 20 6f 74 68 | 65 72 20 63 6f 6e 63 75 |from oth|er concu|
|00000970| 72 72 65 6e 74 20 55 49 | 0d 0a 20 20 20 20 20 20 |rrent UI|.. |
|00000980| 20 20 63 6f 6e 73 74 20 | 6b 50 72 65 66 53 76 63 | const |kPrefSvc|
|00000990| 43 6f 6e 74 72 61 63 74 | 49 44 20 3d 20 22 40 6d |Contract|ID = "@m|
|000009a0| 6f 7a 69 6c 6c 61 2e 6f | 72 67 2f 70 72 65 66 65 |ozilla.o|rg/prefe|
|000009b0| 72 65 6e 63 65 73 2d 73 | 65 72 76 69 63 65 3b 31 |rences-s|ervice;1|
|000009c0| 22 3b 0d 0a 20 20 20 20 | 20 20 20 20 63 6f 6e 73 |";.. | cons|
|000009d0| 74 20 6b 50 72 65 66 53 | 76 63 49 49 44 20 3d 20 |t kPrefS|vcIID = |
|000009e0| 43 6f 6d 70 6f 6e 65 6e | 74 73 2e 69 6e 74 65 72 |Componen|ts.inter|
|000009f0| 66 61 63 65 73 2e 6e 73 | 49 50 72 65 66 53 65 72 |faces.ns|IPrefSer|
|00000a00| 76 69 63 65 3b 0d 0a 20 | 20 20 20 20 20 20 20 76 |vice;.. | v|
|00000a10| 61 72 20 70 72 65 66 53 | 76 63 20 3d 20 43 6f 6d |ar prefS|vc = Com|
|00000a20| 70 6f 6e 65 6e 74 73 2e | 63 6c 61 73 73 65 73 5b |ponents.|classes[|
|00000a30| 6b 50 72 65 66 53 76 63 | 43 6f 6e 74 72 61 63 74 |kPrefSvc|Contract|
|00000a40| 49 44 5d 2e 67 65 74 53 | 65 72 76 69 63 65 28 6b |ID].getS|ervice(k|
|00000a50| 50 72 65 66 53 76 63 49 | 49 44 29 3b 0d 0a 20 20 |PrefSvcI|ID);.. |
|00000a60| 20 20 20 20 20 20 76 61 | 72 20 70 72 65 66 73 20 | va|r prefs |
|00000a70| 3d 20 70 72 65 66 53 76 | 63 2e 67 65 74 42 72 61 |= prefSv|c.getBra|
|00000a80| 6e 63 68 28 6e 75 6c 6c | 29 3b 0d 0a 20 20 20 20 |nch(null|);.. |
|00000a90| 20 20 20 20 63 6f 6e 73 | 74 20 6b 50 72 65 66 42 | cons|t kPrefB|
|00000aa0| 72 61 6e 63 68 49 6e 74 | 65 72 6e 61 6c 49 49 44 |ranchInt|ernalIID|
|00000ab0| 20 3d 20 43 6f 6d 70 6f | 6e 65 6e 74 73 2e 69 6e | = Compo|nents.in|
|00000ac0| 74 65 72 66 61 63 65 73 | 2e 6e 73 49 50 72 65 66 |terfaces|.nsIPref|
|00000ad0| 42 72 61 6e 63 68 49 6e | 74 65 72 6e 61 6c 3b 0d |BranchIn|ternal;.|
|00000ae0| 0a 20 20 20 20 20 20 20 | 20 76 61 72 20 62 6f 6f |. | var boo|
|00000af0| 6b 6d 61 72 6b 73 50 72 | 65 66 73 49 6e 74 65 72 |kmarksPr|efsInter|
|00000b00| 6e 61 6c 20 3d 20 70 72 | 65 66 73 2e 51 75 65 72 |nal = pr|efs.Quer|
|00000b10| 79 49 6e 74 65 72 66 61 | 63 65 28 6b 50 72 65 66 |yInterfa|ce(kPref|
|00000b20| 42 72 61 6e 63 68 49 6e | 74 65 72 6e 61 6c 49 49 |BranchIn|ternalII|
|00000b30| 44 29 3b 0d 0a 20 20 20 | 20 20 20 20 20 62 6f 6f |D);.. | boo|
|00000b40| 6b 6d 61 72 6b 73 50 72 | 65 66 73 49 6e 74 65 72 |kmarksPr|efsInter|
|00000b50| 6e 61 6c 2e 61 64 64 4f | 62 73 65 72 76 65 72 28 |nal.addO|bserver(|
|00000b60| 74 68 69 73 2e 73 6f 72 | 74 43 68 61 6e 67 65 64 |this.sor|tChanged|
|00000b70| 4f 62 73 65 72 76 65 72 | 2e 64 6f 6d 61 69 6e 2c |Observer|.domain,|
|00000b80| 20 0d 0a 20 20 20 20 20 | 20 20 20 20 20 20 20 20 | .. | |
|00000b90| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 20 20 20 | | |
|00000ba0| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 20 74 68 | | th|
|00000bb0| 69 73 2e 73 6f 72 74 43 | 68 61 6e 67 65 64 4f 62 |is.sortC|hangedOb|
|00000bc0| 73 65 72 76 65 72 2c 20 | 66 61 6c 73 65 29 3b 0d |server, |false);.|
|00000bd0| 0a 20 20 20 20 20 20 5d | 5d 3e 3c 2f 63 6f 6e 73 |. ]|]></cons|
|00000be0| 74 72 75 63 74 6f 72 3e | 0d 0a 20 20 20 20 20 20 |tructor>|.. |
|00000bf0| 3c 64 65 73 74 72 75 63 | 74 6f 72 3e 3c 21 5b 43 |<destruc|tor><![C|
|00000c00| 44 41 54 41 5b 0d 0a 20 | 20 20 20 20 20 20 20 0d |DATA[.. | .|
|00000c10| 0a 20 20 20 20 20 20 20 | 20 74 68 69 73 2e 74 72 |. | this.tr|
|00000c20| 65 65 42 75 69 6c 64 65 | 72 2e 72 65 6d 6f 76 65 |eeBuilde|r.remove|
|00000c30| 4f 62 73 65 72 76 65 72 | 28 74 68 69 73 2e 62 75 |Observer|(this.bu|
|00000c40| 69 6c 64 65 72 4f 62 73 | 65 72 76 65 72 29 3b 0d |ilderObs|erver);.|
|00000c50| 0a 20 20 20 20 20 20 20 | 20 74 68 69 73 2e 74 72 |. | this.tr|
|00000c60| 65 65 2e 63 6f 6e 74 72 | 6f 6c 6c 65 72 73 2e 72 |ee.contr|ollers.r|
|00000c70| 65 6d 6f 76 65 43 6f 6e | 74 72 6f 6c 6c 65 72 28 |emoveCon|troller(|
|00000c80| 74 68 69 73 2e 63 6f 6e | 74 72 6f 6c 6c 65 72 29 |this.con|troller)|
|00000c90| 3b 0d 0a 0d 0a 20 20 20 | 20 20 20 20 20 2f 2f 20 |;.... | // |
|00000ca0| 53 61 76 65 20 63 6f 6c | 75 6d 6e 20 73 65 74 74 |Save col|umn sett|
|00000cb0| 69 6e 67 73 20 61 6e 64 | 20 73 6f 72 74 20 69 6e |ings and| sort in|
|00000cc0| 66 6f 20 74 6f 20 70 65 | 72 73 69 73 74 65 64 20 |fo to pe|rsisted |
|00000cd0| 61 74 74 72 69 62 75 74 | 65 0d 0a 20 20 20 20 20 |attribut|e.. |
|00000ce0| 20 20 20 76 61 72 20 70 | 65 72 73 69 73 74 53 74 | var p|ersistSt|
|00000cf0| 72 69 6e 67 20 3d 20 22 | 22 3b 0d 0a 20 20 20 20 |ring = "|";.. |
|00000d00| 20 20 20 20 0d 0a 20 20 | 20 20 20 20 20 20 76 61 | .. | va|
|00000d10| 72 20 73 6f 72 74 52 65 | 73 6f 75 72 63 65 20 3d |r sortRe|source =|
|00000d20| 20 4e 43 5f 4e 53 20 2b | 20 22 4e 61 6d 65 22 3b | NC_NS +| "Name";|
|00000d30| 0d 0a 20 20 20 20 20 20 | 20 20 76 61 72 20 73 6f |.. | var so|
|00000d40| 72 74 44 69 72 65 63 74 | 69 6f 6e 20 3d 20 22 6e |rtDirect|ion = "n|
|00000d50| 6f 6e 65 22 3b 0d 0a 0d | 0a 20 20 20 20 20 20 20 |one";...|. |
|00000d60| 20 76 61 72 20 74 72 65 | 65 63 6f 6c 73 20 3d 20 | var tre|ecols = |
|00000d70| 64 6f 63 75 6d 65 6e 74 | 2e 67 65 74 41 6e 6f 6e |document|.getAnon|
|00000d80| 79 6d 6f 75 73 45 6c 65 | 6d 65 6e 74 42 79 41 74 |ymousEle|mentByAt|
|00000d90| 74 72 69 62 75 74 65 28 | 74 68 69 73 2c 20 22 61 |tribute(|this, "a|
|00000da0| 6e 6f 6e 69 64 22 2c 20 | 22 74 72 65 65 63 6f 6c |nonid", |"treecol|
|00000db0| 73 22 29 3b 0d 0a 20 20 | 20 20 20 20 20 20 76 61 |s");.. | va|
|00000dc0| 72 20 63 68 69 6c 64 20 | 3d 20 74 72 65 65 63 6f |r child |= treeco|
|00000dd0| 6c 73 2e 66 69 72 73 74 | 43 68 69 6c 64 3b 0d 0a |ls.first|Child;..|
|00000de0| 20 20 20 20 20 20 20 20 | 77 68 69 6c 65 20 28 63 | |while (c|
|00000df0| 68 69 6c 64 29 20 7b 0d | 0a 20 20 20 20 20 20 20 |hild) {.|. |
|00000e00| 20 20 20 69 66 20 28 63 | 68 69 6c 64 2e 6c 6f 63 | if (c|hild.loc|
|00000e10| 61 6c 4e 61 6d 65 20 21 | 3d 20 22 73 70 6c 69 74 |alName !|= "split|
|00000e20| 74 65 72 22 29 20 7b 0d | 0a 20 20 20 20 20 20 20 |ter") {.|. |
|00000e30| 20 20 20 20 20 76 61 72 | 20 66 6f 72 6d 61 74 53 | var| formatS|
|00000e40| 74 72 69 6e 67 20 3d 20 | 22 20 63 6f 6c 3a 25 31 |tring = |" col:%1|
|00000e50| 25 3f 77 69 64 74 68 3d | 25 32 25 26 68 69 64 64 |%?width=|%2%&hidd|
|00000e60| 65 6e 3d 25 33 25 26 6f | 72 64 69 6e 61 6c 3d 25 |en=%3%&o|rdinal=%|
|00000e70| 36 25 22 3b 0d 0a 20 20 | 20 20 20 20 20 20 20 20 |6%";.. | |
|00000e80| 20 20 66 6f 72 6d 61 74 | 53 74 72 69 6e 67 20 3d | format|String =|
|00000e90| 20 66 6f 72 6d 61 74 53 | 74 72 69 6e 67 2e 72 65 | formatS|tring.re|
|00000ea0| 70 6c 61 63 65 28 2f 25 | 31 25 2f 2c 20 63 68 69 |place(/%|1%/, chi|
|00000eb0| 6c 64 2e 67 65 74 41 74 | 74 72 69 62 75 74 65 28 |ld.getAt|tribute(|
|00000ec0| 22 69 64 22 29 29 3b 0d | 0a 20 20 20 20 20 20 20 |"id"));.|. |
|00000ed0| 20 20 20 20 20 66 6f 72 | 6d 61 74 53 74 72 69 6e | for|matStrin|
|00000ee0| 67 20 3d 20 66 6f 72 6d | 61 74 53 74 72 69 6e 67 |g = form|atString|
|00000ef0| 2e 72 65 70 6c 61 63 65 | 28 2f 25 32 25 2f 2c 20 |.replace|(/%2%/, |
|00000f00| 63 68 69 6c 64 2e 67 65 | 74 41 74 74 72 69 62 75 |child.ge|tAttribu|
|00000f10| 74 65 28 22 77 69 64 74 | 68 22 29 29 3b 0d 0a 20 |te("widt|h"));.. |
|00000f20| 20 20 20 20 20 20 20 20 | 20 20 20 66 6f 72 6d 61 | | forma|
|00000f30| 74 53 74 72 69 6e 67 20 | 3d 20 66 6f 72 6d 61 74 |tString |= format|
|00000f40| 53 74 72 69 6e 67 2e 72 | 65 70 6c 61 63 65 28 2f |String.r|eplace(/|
|00000f50| 25 33 25 2f 2c 20 63 68 | 69 6c 64 2e 67 65 74 41 |%3%/, ch|ild.getA|
|00000f60| 74 74 72 69 62 75 74 65 | 28 22 68 69 64 64 65 6e |ttribute|("hidden|
|00000f70| 22 29 29 3b 0d 0a 0d 0a | 20 20 20 20 20 20 20 20 |"));....| |
|00000f80| 20 20 20 20 2f 2f 20 57 | 68 69 6c 65 20 77 65 27 | // W|hile we'|
|00000f90| 72 65 20 77 61 6c 6b 69 | 6e 67 20 74 68 65 20 63 |re walki|ng the c|
|00000fa0| 6f 6c 75 6d 6e 73 2c 20 | 69 66 20 77 65 20 64 69 |olumns, |if we di|
|00000fb0| 73 63 6f 76 65 72 20 74 | 68 65 20 63 6f 6c 75 6d |scover t|he colum|
|00000fc0| 6e 20 74 68 61 74 20 72 | 65 70 72 65 73 65 6e 74 |n that r|epresent|
|00000fd0| 73 20 74 68 65 0d 0a 20 | 20 20 20 20 20 20 20 20 |s the.. | |
|00000fe0| 20 20 20 2f 2f 20 66 69 | 65 6c 64 20 73 6f 72 74 | // fi|eld sort|
|00000ff0| 65 64 20 62 79 2c 20 73 | 61 76 65 20 74 68 65 20 |ed by, s|ave the |
|00001000| 72 65 73 6f 75 72 63 65 | 20 61 73 73 6f 63 69 61 |resource| associa|
|00001010| 74 65 64 20 77 69 74 68 | 20 74 68 61 74 20 63 6f |ted with| that co|
|00001020| 6c 75 6d 6e 20 73 6f 20 | 74 68 61 74 20 77 65 20 |lumn so |that we |
|00001030| 0d 0a 20 20 20 20 20 20 | 20 20 20 20 20 20 2f 2f |.. | //|
|00001040| 20 63 61 6e 20 73 61 76 | 65 20 74 68 61 74 20 69 | can sav|e that i|
|00001050| 6e 20 70 72 65 66 73 20 | 28 73 65 65 20 62 65 6c |n prefs |(see bel|
|00001060| 6f 77 29 0d 0a 20 20 20 | 20 20 20 20 20 20 20 20 |ow).. | |
|00001070| 20 69 66 20 28 63 68 69 | 6c 64 2e 67 65 74 41 74 | if (chi|ld.getAt|
|00001080| 74 72 69 62 75 74 65 28 | 22 73 6f 72 74 41 63 74 |tribute(|"sortAct|
|00001090| 69 76 65 22 29 20 3d 3d | 20 22 74 72 75 65 22 29 |ive") ==| "true")|
|000010a0| 20 7b 0d 0a 20 20 20 20 | 20 20 20 20 20 20 20 20 | {.. | |
|000010b0| 20 20 73 6f 72 74 52 65 | 73 6f 75 72 63 65 20 3d | sortRe|source =|
|000010c0| 20 63 68 69 6c 64 2e 67 | 65 74 41 74 74 72 69 62 | child.g|etAttrib|
|000010d0| 75 74 65 28 22 73 6f 72 | 74 22 29 3b 0d 0a 20 20 |ute("sor|t");.. |
|000010e0| 20 20 20 20 20 20 20 20 | 20 20 20 20 73 6f 72 74 | | sort|
|000010f0| 44 69 72 65 63 74 69 6f | 6e 20 3d 20 63 68 69 6c |Directio|n = chil|
|00001100| 64 2e 67 65 74 41 74 74 | 72 69 62 75 74 65 28 22 |d.getAtt|ribute("|
|00001110| 73 6f 72 74 44 69 72 65 | 63 74 69 6f 6e 22 29 3b |sortDire|ction");|
|00001120| 0d 0a 20 20 20 20 20 20 | 20 20 20 20 20 20 7d 0d |.. | }.|
|00001130| 0a 20 20 20 20 20 20 20 | 20 20 20 20 20 66 6f 72 |. | for|
|00001140| 6d 61 74 53 74 72 69 6e | 67 20 3d 20 66 6f 72 6d |matStrin|g = form|
|00001150| 61 74 53 74 72 69 6e 67 | 2e 72 65 70 6c 61 63 65 |atString|.replace|
|00001160| 28 2f 25 36 25 2f 2c 20 | 63 68 69 6c 64 2e 67 65 |(/%6%/, |child.ge|
|00001170| 74 41 74 74 72 69 62 75 | 74 65 28 22 6f 72 64 69 |tAttribu|te("ordi|
|00001180| 6e 61 6c 22 29 29 3b 0d | 0a 20 20 20 20 20 20 20 |nal"));.|. |
|00001190| 20 20 20 20 20 70 65 72 | 73 69 73 74 53 74 72 69 | per|sistStri|
|000011a0| 6e 67 20 2b 3d 20 66 6f | 72 6d 61 74 53 74 72 69 |ng += fo|rmatStri|
|000011b0| 6e 67 3b 0d 0a 20 20 20 | 20 20 20 20 20 20 20 7d |ng;.. | }|
|000011c0| 0d 0a 20 20 20 20 20 20 | 20 20 20 20 63 68 69 6c |.. | chil|
|000011d0| 64 20 3d 20 63 68 69 6c | 64 2e 6e 65 78 74 53 69 |d = chil|d.nextSi|
|000011e0| 62 6c 69 6e 67 3b 0d 0a | 20 20 20 20 20 20 20 20 |bling;..| |
|000011f0| 7d 0d 0a 20 20 20 20 20 | 20 20 20 74 68 69 73 2e |}.. | this.|
|00001200| 73 65 74 41 74 74 72 69 | 62 75 74 65 28 22 63 6f |setAttri|bute("co|
|00001210| 6c 69 6e 66 6f 22 2c 20 | 70 65 72 73 69 73 74 53 |linfo", |persistS|
|00001220| 74 72 69 6e 67 29 3b 0d | 0a 20 20 20 20 20 20 20 |tring);.|. |
|00001230| 20 0d 0a 20 20 20 20 20 | 20 20 20 64 6f 63 75 6d | .. | docum|
|00001240| 65 6e 74 2e 70 65 72 73 | 69 73 74 28 74 68 69 73 |ent.pers|ist(this|
|00001250| 2e 69 64 2c 20 22 63 6f | 6c 69 6e 66 6f 22 29 3b |.id, "co|linfo");|
|00001260| 0d 0a 20 20 20 20 20 20 | 20 20 0d 0a 20 20 20 20 |.. | .. |
|00001270| 20 20 20 20 2f 2f 20 55 | 6e 68 6f 6f 6b 20 74 68 | // U|nhook th|
|00001280| 65 20 73 6f 72 74 20 63 | 68 61 6e 67 65 20 6f 62 |e sort c|hange ob|
|00001290| 73 65 72 76 65 72 20 66 | 6f 72 20 74 68 69 73 20 |server f|or this |
|000012a0| 74 72 65 65 0d 0a 20 20 | 20 20 20 20 20 20 63 6f |tree.. | co|
|000012b0| 6e 73 74 20 6b 50 72 65 | 66 53 76 63 43 6f 6e 74 |nst kPre|fSvcCont|
|000012c0| 72 61 63 74 49 44 20 3d | 20 22 40 6d 6f 7a 69 6c |ractID =| "@mozil|
|000012d0| 6c 61 2e 6f 72 67 2f 70 | 72 65 66 65 72 65 6e 63 |la.org/p|referenc|
|000012e0| 65 73 2d 73 65 72 76 69 | 63 65 3b 31 22 3b 0d 0a |es-servi|ce;1";..|
|000012f0| 20 20 20 20 20 20 20 20 | 63 6f 6e 73 74 20 6b 50 | |const kP|
|00001300| 72 65 66 53 76 63 49 49 | 44 20 3d 20 43 6f 6d 70 |refSvcII|D = Comp|
|00001310| 6f 6e 65 6e 74 73 2e 69 | 6e 74 65 72 66 61 63 65 |onents.i|nterface|
|00001320| 73 2e 6e 73 49 50 72 65 | 66 53 65 72 76 69 63 65 |s.nsIPre|fService|
|00001330| 3b 0d 0a 20 20 20 20 20 | 20 20 20 76 61 72 20 70 |;.. | var p|
|00001340| 72 65 66 53 76 63 20 3d | 20 43 6f 6d 70 6f 6e 65 |refSvc =| Compone|
|00001350| 6e 74 73 2e 63 6c 61 73 | 73 65 73 5b 6b 50 72 65 |nts.clas|ses[kPre|
|00001360| 66 53 76 63 43 6f 6e 74 | 72 61 63 74 49 44 5d 2e |fSvcCont|ractID].|
|00001370| 67 65 74 53 65 72 76 69 | 63 65 28 6b 50 72 65 66 |getServi|ce(kPref|
|00001380| 53 76 63 49 49 44 29 3b | 0d 0a 20 20 20 20 20 20 |SvcIID);|.. |
|00001390| 20 20 76 61 72 20 70 72 | 65 66 73 20 3d 20 70 72 | var pr|efs = pr|
|000013a0| 65 66 53 76 63 2e 67 65 | 74 42 72 61 6e 63 68 28 |efSvc.ge|tBranch(|
|000013b0| 6e 75 6c 6c 29 3b 0d 0a | 20 20 20 20 20 20 20 20 |null);..| |
|000013c0| 63 6f 6e 73 74 20 6b 50 | 72 65 66 42 72 61 6e 63 |const kP|refBranc|
|000013d0| 68 49 6e 74 65 72 6e 61 | 6c 49 49 44 20 3d 20 43 |hInterna|lIID = C|
|000013e0| 6f 6d 70 6f 6e 65 6e 74 | 73 2e 69 6e 74 65 72 66 |omponent|s.interf|
|000013f0| 61 63 65 73 2e 6e 73 49 | 50 72 65 66 42 72 61 6e |aces.nsI|PrefBran|
|00001400| 63 68 49 6e 74 65 72 6e | 61 6c 3b 0d 0a 20 20 20 |chIntern|al;.. |
|00001410| 20 20 20 20 20 76 61 72 | 20 62 6f 6f 6b 6d 61 72 | var| bookmar|
|00001420| 6b 73 50 72 65 66 73 49 | 6e 74 65 72 6e 61 6c 20 |ksPrefsI|nternal |
|00001430| 3d 20 70 72 65 66 73 2e | 51 75 65 72 79 49 6e 74 |= prefs.|QueryInt|
|00001440| 65 72 66 61 63 65 28 6b | 50 72 65 66 42 72 61 6e |erface(k|PrefBran|
|00001450| 63 68 49 6e 74 65 72 6e | 61 6c 49 49 44 29 3b 0d |chIntern|alIID);.|
|00001460| 0a 20 20 20 20 20 20 20 | 20 62 6f 6f 6b 6d 61 72 |. | bookmar|
|00001470| 6b 73 50 72 65 66 73 49 | 6e 74 65 72 6e 61 6c 2e |ksPrefsI|nternal.|
|00001480| 72 65 6d 6f 76 65 4f 62 | 73 65 72 76 65 72 28 74 |removeOb|server(t|
|00001490| 68 69 73 2e 73 6f 72 74 | 43 68 61 6e 67 65 64 4f |his.sort|ChangedO|
|000014a0| 62 73 65 72 76 65 72 2e | 64 6f 6d 61 69 6e 2c 20 |bserver.|domain, |
|000014b0| 0d 0a 20 20 20 20 20 20 | 20 20 20 20 20 20 20 20 |.. | |
|000014c0| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 20 20 20 | | |
|000014d0| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 20 20 20 | | |
|000014e0| 74 68 69 73 2e 73 6f 72 | 74 43 68 61 6e 67 65 64 |this.sor|tChanged|
|000014f0| 4f 62 73 65 72 76 65 72 | 29 3b 0d 0a 0d 0a 20 20 |Observer|);.... |
|00001500| 20 20 20 20 5d 5d 3e 3c | 2f 64 65 73 74 72 75 63 | ]]><|/destruc|
|00001510| 74 6f 72 3e 0d 0a 0d 0a | 20 20 20 20 20 20 3c 70 |tor>....| <p|
|00001520| 72 6f 70 65 72 74 79 20 | 6e 61 6d 65 3d 22 64 62 |roperty |name="db|
|00001530| 22 3e 0d 0a 20 20 20 20 | 20 20 20 20 3c 67 65 74 |">.. | <get|
|00001540| 74 65 72 3e 3c 21 5b 43 | 44 41 54 41 5b 0d 0a 20 |ter><![C|DATA[.. |
|00001550| 20 20 20 20 20 20 20 20 | 20 72 65 74 75 72 6e 20 | | return |
|00001560| 74 68 69 73 2e 74 72 65 | 65 2e 64 61 74 61 62 61 |this.tre|e.databa|
|00001570| 73 65 3b 0d 0a 20 20 20 | 20 20 20 20 20 5d 5d 3e |se;.. | ]]>|
|00001580| 3c 2f 67 65 74 74 65 72 | 3e 0d 0a 20 20 20 20 20 |</getter|>.. |
|00001590| 20 3c 2f 70 72 6f 70 65 | 72 74 79 3e 20 20 20 20 | </prope|rty> |
|000015a0| 20 20 0d 0a 20 20 20 20 | 20 20 0d 0a 20 20 20 20 | .. | .. |
|000015b0| 20 20 3c 66 69 65 6c 64 | 20 6e 61 6d 65 3d 22 73 | <field| name="s|
|000015c0| 6f 72 74 43 68 61 6e 67 | 65 64 4f 62 73 65 72 76 |ortChang|edObserv|
|000015d0| 65 72 22 3e 0d 0a 20 20 | 20 20 20 20 3c 21 5b 43 |er">.. | <![C|
|000015e0| 44 41 54 41 5b 0d 0a 20 | 20 20 20 20 20 28 7b 0d |DATA[.. | ({.|
|000015f0| 0a 20 20 20 20 20 20 20 | 20 6f 75 74 65 72 3a 20 |. | outer: |
|00001600| 74 68 69 73 2c 0d 0a 20 | 20 20 20 20 20 20 20 64 |this,.. | d|
|00001610| 6f 6d 61 69 6e 3a 20 22 | 62 72 6f 77 73 65 72 2e |omain: "|browser.|
|00001620| 62 6f 6f 6b 6d 61 72 6b | 73 2e 73 6f 72 74 22 2c |bookmark|s.sort",|
|00001630| 0d 0a 20 20 20 20 20 20 | 20 20 6f 62 73 65 72 76 |.. | observ|
|00001640| 65 3a 20 66 75 6e 63 74 | 69 6f 6e 20 42 4d 4f 4c |e: funct|ion BMOL|
|00001650| 5f 73 6f 72 74 43 68 61 | 6e 67 65 64 4f 62 73 65 |_sortCha|ngedObse|
|00001660| 72 76 65 72 28 61 53 75 | 62 6a 65 63 74 2c 20 61 |rver(aSu|bject, a|
|00001670| 54 6f 70 69 63 2c 20 61 | 50 72 65 66 4e 61 6d 65 |Topic, a|PrefName|
|00001680| 29 20 0d 0a 20 20 20 20 | 20 20 20 20 7b 0d 0a 20 |) .. | {.. |
|00001690| 20 20 20 20 20 20 20 20 | 20 69 66 20 28 61 54 6f | | if (aTo|
|000016a0| 70 69 63 20 21 3d 20 22 | 6e 73 50 72 65 66 3a 63 |pic != "|nsPref:c|
|000016b0| 68 61 6e 67 65 64 22 29 | 20 72 65 74 75 72 6e 3b |hanged")| return;|
|000016c0| 0d 0a 20 20 20 20 20 20 | 20 20 20 20 69 66 20 28 |.. | if (|
|000016d0| 61 50 72 65 66 4e 61 6d | 65 2e 73 75 62 73 74 72 |aPrefNam|e.substr|
|000016e0| 28 30 2c 20 74 68 69 73 | 2e 64 6f 6d 61 69 6e 2e |(0, this|.domain.|
|000016f0| 6c 65 6e 67 74 68 29 20 | 21 3d 20 74 68 69 73 2e |length) |!= this.|
|00001700| 64 6f 6d 61 69 6e 29 20 | 72 65 74 75 72 6e 3b 0d |domain) |return;.|
|00001710| 0a 20 20 20 20 20 20 20 | 20 20 20 20 20 20 20 20 |. | |
|00001720| 20 20 20 20 20 0d 0a 20 | 20 20 20 20 20 20 20 20 | .. | |
|00001730| 20 74 68 69 73 2e 6f 75 | 74 65 72 2e 72 65 66 72 | this.ou|ter.refr|
|00001740| 65 73 68 53 6f 72 74 28 | 29 3b 0d 0a 20 20 20 20 |eshSort(|);.. |
|00001750| 20 20 20 20 7d 20 20 20 | 20 20 20 0d 0a 20 20 20 | } | .. |
|00001760| 20 20 20 7d 29 0d 0a 20 | 20 20 20 20 20 5d 5d 3e | }).. | ]]>|
|00001770| 0d 0a 20 20 20 20 20 20 | 3c 2f 66 69 65 6c 64 3e |.. |</field>|
|00001780| 0d 0a 20 20 20 20 20 20 | 0d 0a 20 20 20 20 20 20 |.. |.. |
|00001790| 3c 66 69 65 6c 64 20 6e | 61 6d 65 3d 22 73 6f 72 |<field n|ame="sor|
|000017a0| 74 65 64 22 3e 66 61 6c | 73 65 3c 2f 66 69 65 6c |ted">fal|se</fiel|
|000017b0| 64 3e 0d 0a 20 20 20 20 | 20 20 3c 6d 65 74 68 6f |d>.. | <metho|
|000017c0| 64 20 6e 61 6d 65 3d 22 | 72 65 66 72 65 73 68 53 |d name="|refreshS|
|000017d0| 6f 72 74 22 3e 0d 0a 20 | 20 20 20 20 20 20 20 3c |ort">.. | <|
|000017e0| 62 6f 64 79 3e 0d 0a 20 | 20 20 20 20 20 20 20 3c |body>.. | <|
|000017f0| 21 5b 43 44 41 54 41 5b | 0d 0a 20 20 20 20 20 20 |![CDATA[|.. |
|00001800| 20 20 20 20 63 6f 6e 73 | 74 20 6b 50 72 65 66 53 | cons|t kPrefS|
|00001810| 76 63 43 6f 6e 74 72 61 | 63 74 49 44 20 3d 20 22 |vcContra|ctID = "|
|00001820| 40 6d 6f 7a 69 6c 6c 61 | 2e 6f 72 67 2f 70 72 65 |@mozilla|.org/pre|
|00001830| 66 65 72 65 6e 63 65 73 | 2d 73 65 72 76 69 63 65 |ferences|-service|
|00001840| 3b 31 22 3b 0d 0a 20 20 | 20 20 20 20 20 20 20 20 |;1";.. | |
|00001850| 63 6f 6e 73 74 20 6b 50 | 72 65 66 53 76 63 49 49 |const kP|refSvcII|
|00001860| 44 20 3d 20 43 6f 6d 70 | 6f 6e 65 6e 74 73 2e 69 |D = Comp|onents.i|
|00001870| 6e 74 65 72 66 61 63 65 | 73 2e 6e 73 49 50 72 65 |nterface|s.nsIPre|
|00001880| 66 53 65 72 76 69 63 65 | 3b 0d 0a 20 20 20 20 20 |fService|;.. |
|00001890| 20 20 20 20 20 76 61 72 | 20 70 72 65 66 53 76 63 | var| prefSvc|
|000018a0| 20 3d 20 43 6f 6d 70 6f | 6e 65 6e 74 73 2e 63 6c | = Compo|nents.cl|
|000018b0| 61 73 73 65 73 5b 6b 50 | 72 65 66 53 76 63 43 6f |asses[kP|refSvcCo|
|000018c0| 6e 74 72 61 63 74 49 44 | 5d 2e 67 65 74 53 65 72 |ntractID|].getSer|
|000018d0| 76 69 63 65 28 6b 50 72 | 65 66 53 76 63 49 49 44 |vice(kPr|efSvcIID|
|000018e0| 29 3b 0d 0a 20 20 20 20 | 20 20 20 20 20 20 76 61 |);.. | va|
|000018f0| 72 20 62 6f 6f 6b 6d 61 | 72 6b 73 53 6f 72 74 50 |r bookma|rksSortP|
|00001900| 72 65 66 73 20 3d 20 70 | 72 65 66 53 76 63 2e 67 |refs = p|refSvc.g|
|00001910| 65 74 42 72 61 6e 63 68 | 28 22 62 72 6f 77 73 65 |etBranch|("browse|
|00001920| 72 2e 62 6f 6f 6b 6d 61 | 72 6b 73 2e 73 6f 72 74 |r.bookma|rks.sort|
|00001930| 2e 22 29 3b 0d 0a 20 20 | 20 20 20 20 20 20 20 20 |.");.. | |
|00001940| 0d 0a 20 20 20 20 20 20 | 20 20 20 20 2f 2f 20 54 |.. | // T|
|00001950| 68 69 73 20 65 6e 73 75 | 72 65 73 20 74 68 61 74 |his ensu|res that|
|00001960| 20 77 65 20 64 6f 6e 27 | 74 20 73 6f 72 74 20 74 | we don'|t sort t|
|00001970| 77 69 63 65 20 69 6e 20 | 74 68 65 20 74 72 65 65 |wice in |the tree|
|00001980| 20 74 68 61 74 20 69 73 | 20 63 6c 69 63 6b 65 64 | that is| clicked|
|00001990| 20 6f 6e 20 0d 0a 20 20 | 20 20 20 20 20 20 20 20 | on .. | |
|000019a0| 2f 2f 20 61 73 20 61 20 | 72 65 73 75 6c 74 20 6f |// as a |result o|
|000019b0| 66 20 31 29 20 74 68 65 | 20 63 6c 69 63 6b 20 61 |f 1) the| click a|
|000019c0| 6e 64 20 32 29 20 74 68 | 65 20 70 72 65 66 20 6c |nd 2) th|e pref l|
|000019d0| 69 73 74 65 6e 65 72 2e | 20 0d 0a 20 20 20 20 20 |istener.| .. |
|000019e0| 20 20 20 20 20 69 66 20 | 28 21 74 68 69 73 2e 73 | if |(!this.s|
|000019f0| 6f 72 74 65 64 29 20 7b | 0d 0a 20 20 20 20 20 20 |orted) {|.. |
|00001a00| 20 20 20 20 20 20 74 72 | 79 20 7b 0d 0a 20 20 20 | tr|y {.. |
|00001a10| 20 20 20 20 20 20 20 20 | 20 20 20 76 61 72 20 73 | | var s|
|00001a20| 6f 72 74 52 65 73 6f 75 | 72 63 65 20 3d 20 62 6f |ortResou|rce = bo|
|00001a30| 6f 6b 6d 61 72 6b 73 53 | 6f 72 74 50 72 65 66 73 |okmarksS|ortPrefs|
|00001a40| 2e 67 65 74 43 68 61 72 | 50 72 65 66 28 22 72 65 |.getChar|Pref("re|
|00001a50| 73 6f 75 72 63 65 22 29 | 3b 0d 0a 20 20 20 20 20 |source")|;.. |
|00001a60| 20 20 20 20 20 20 20 20 | 20 76 61 72 20 73 6f 72 | | var sor|
|00001a70| 74 44 69 72 65 63 74 69 | 6f 6e 20 3d 20 62 6f 6f |tDirecti|on = boo|
|00001a80| 6b 6d 61 72 6b 73 53 6f | 72 74 50 72 65 66 73 2e |kmarksSo|rtPrefs.|
|00001a90| 67 65 74 43 68 61 72 50 | 72 65 66 28 22 64 69 72 |getCharP|ref("dir|
|00001aa0| 65 63 74 69 6f 6e 22 29 | 3b 0d 0a 20 20 20 20 20 |ection")|;.. |
|00001ab0| 20 20 20 20 20 0d 0a 20 | 20 20 20 20 20 20 20 20 | .. | |
|00001ac0| 20 20 20 20 20 2f 2f 20 | 57 61 6c 6b 20 74 68 65 | // |Walk the|
|00001ad0| 20 63 6f 6c 75 6d 6e 73 | 2c 20 77 68 65 6e 20 77 | columns|, when w|
|00001ae0| 65 20 66 69 6e 64 20 61 | 20 63 6f 6c 75 6d 6e 20 |e find a| column |
|00001af0| 77 69 74 68 20 61 20 73 | 6f 72 74 20 72 65 73 6f |with a s|ort reso|
|00001b00| 75 72 63 65 20 74 68 61 | 74 20 6d 61 74 63 68 65 |urce tha|t matche|
|00001b10| 73 20 74 68 65 20 73 75 | 70 70 6c 69 65 64 0d 0a |s the su|pplied..|
|00001b20| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 20 2f 2f | | //|
|00001b30| 20 64 61 74 61 2c 20 73 | 74 6f 70 20 61 6e 64 20 | data, s|top and |
|00001b40| 6d 61 6b 65 20 73 75 72 | 65 20 69 74 27 73 20 73 |make sur|e it's s|
|00001b50| 6f 72 74 20 61 63 74 69 | 76 65 2e 20 0d 0a 20 20 |ort acti|ve. .. |
|00001b60| 20 20 20 20 20 20 20 20 | 20 20 20 20 76 61 72 20 | | var |
|00001b70| 74 72 65 65 63 6f 6c 73 | 20 3d 20 64 6f 63 75 6d |treecols| = docum|
|00001b80| 65 6e 74 2e 67 65 74 41 | 6e 6f 6e 79 6d 6f 75 73 |ent.getA|nonymous|
|00001b90| 45 6c 65 6d 65 6e 74 42 | 79 41 74 74 72 69 62 75 |ElementB|yAttribu|
|00001ba0| 74 65 28 74 68 69 73 2c | 20 22 61 6e 6f 6e 69 64 |te(this,| "anonid|
|00001bb0| 22 2c 20 22 74 72 65 65 | 63 6f 6c 73 22 29 3b 0d |", "tree|cols");.|
|00001bc0| 0a 20 20 20 20 20 20 20 | 20 20 20 20 20 20 20 76 |. | v|
|00001bd0| 61 72 20 63 68 69 6c 64 | 20 3d 20 74 72 65 65 63 |ar child| = treec|
|00001be0| 6f 6c 73 2e 66 69 72 73 | 74 43 68 69 6c 64 3b 0d |ols.firs|tChild;.|
|00001bf0| 0a 20 20 20 20 20 20 20 | 20 20 20 20 20 20 20 77 |. | w|
|00001c00| 68 69 6c 65 20 28 63 68 | 69 6c 64 29 20 7b 0d 0a |hile (ch|ild) {..|
|00001c10| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 20 20 20 | | |
|00001c20| 69 66 20 28 63 68 69 6c | 64 2e 6c 6f 63 61 6c 4e |if (chil|d.localN|
|00001c30| 61 6d 65 20 21 3d 20 22 | 73 70 6c 69 74 74 65 72 |ame != "|splitter|
|00001c40| 22 29 20 7b 0d 0a 20 20 | 20 20 20 20 20 20 20 20 |") {.. | |
|00001c50| 20 20 20 20 20 20 20 20 | 69 66 20 28 63 68 69 6c | |if (chil|
|00001c60| 64 2e 67 65 74 41 74 74 | 72 69 62 75 74 65 28 22 |d.getAtt|ribute("|
|00001c70| 73 6f 72 74 22 29 20 3d | 3d 20 73 6f 72 74 52 65 |sort") =|= sortRe|
|00001c80| 73 6f 75 72 63 65 29 20 | 7b 0d 0a 20 20 20 20 20 |source) |{.. |
|00001c90| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 20 20 63 | | c|
|00001ca0| 68 69 6c 64 2e 73 65 74 | 41 74 74 72 69 62 75 74 |hild.set|Attribut|
|00001cb0| 65 28 22 73 6f 72 74 41 | 63 74 69 76 65 22 2c 20 |e("sortA|ctive", |
|00001cc0| 22 74 72 75 65 22 29 3b | 0d 0a 20 20 20 20 20 20 |"true");|.. |
|00001cd0| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 20 63 68 | | ch|
|00001ce0| 69 6c 64 2e 73 65 74 41 | 74 74 72 69 62 75 74 65 |ild.setA|ttribute|
|00001cf0| 28 22 73 6f 72 74 44 69 | 72 65 63 74 69 6f 6e 22 |("sortDi|rection"|
|00001d00| 2c 20 73 6f 72 74 44 69 | 72 65 63 74 69 6f 6e 29 |, sortDi|rection)|
|00001d10| 3b 0d 0a 20 20 20 20 20 | 20 20 20 20 20 20 20 20 |;.. | |
|00001d20| 20 20 20 20 20 20 20 74 | 68 69 73 2e 74 72 65 65 | t|his.tree|
|00001d30| 42 75 69 6c 64 65 72 2e | 73 6f 72 74 28 63 68 69 |Builder.|sort(chi|
|00001d40| 6c 64 2c 20 66 61 6c 73 | 65 29 3b 0d 0a 20 20 20 |ld, fals|e);.. |
|00001d50| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 20 20 20 | | |
|00001d60| 20 62 72 65 61 6b 3b 0d | 0a 20 20 20 20 20 20 20 | break;.|. |
|00001d70| 20 20 20 20 20 20 20 20 | 20 20 20 7d 0d 0a 20 20 | | }.. |
|00001d80| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 20 7d 20 | | } |
|00001d90| 20 20 20 20 20 20 20 20 | 20 0d 0a 20 20 20 20 20 | | .. |
|00001da0| 20 20 20 20 20 20 20 20 | 20 20 20 63 68 69 6c 64 | | child|
|00001db0| 20 3d 20 63 68 69 6c 64 | 2e 6e 65 78 74 53 69 62 | = child|.nextSib|
|00001dc0| 6c 69 6e 67 3b 0d 0a 20 | 20 20 20 20 20 20 20 20 |ling;.. | |
|00001dd0| 20 20 20 20 20 7d 0d 0a | 20 20 20 20 20 20 20 20 | }..| |
|00001de0| 20 20 20 20 7d 0d 0a 20 | 20 20 20 20 20 20 20 20 | }.. | |
|00001df0| 20 20 20 63 61 74 63 68 | 20 28 65 29 20 7b 0d 0a | catch| (e) {..|
|00001e00| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 20 64 75 | | du|
|00001e10| 6d 70 28 22 65 72 72 6f | 72 20 69 6e 20 72 65 66 |mp("erro|r in ref|
|00001e20| 72 65 73 68 20 73 6f 72 | 74 3a 22 2b 65 29 0d 0a |resh sor|t:"+e)..|
|00001e30| 20 20 20 20 20 20 20 20 | 20 20 20 20 7d 0d 0a 20 | | }.. |
|00001e40| 20 20 20 20 20 20 20 20 | 20 7d 0d 0a 0d 0a 20 20 | | }.... |
|00001e50| 20 20 20 20 20 20 20 20 | 74 68 69 73 2e 73 6f 72 | |this.sor|
|00001e60| 74 65 64 20 3d 20 66 61 | 6c 73 65 3b 0d 0a 20 20 |ted = fa|lse;.. |
|00001e70| 20 20 20 20 20 20 5d 5d | 3e 0d 0a 20 20 20 20 20 | ]]|>.. |
|00001e80| 20 20 20 3c 2f 62 6f 64 | 79 3e 0d 0a 20 20 20 20 | </bod|y>.. |
|00001e90| 20 20 3c 2f 6d 65 74 68 | 6f 64 3e 0d 0a 20 20 20 | </meth|od>.. |
|00001ea0| 20 20 20 0d 0a 20 20 20 | 20 20 20 3c 70 72 6f 70 | .. | <prop|
|00001eb0| 65 72 74 79 20 6e 61 6d | 65 3d 22 63 6f 6c 75 6d |erty nam|e="colum|
|00001ec0| 6e 73 22 3e 0d 0a 20 20 | 20 20 20 20 20 20 3c 67 |ns">.. | <g|
|00001ed0| 65 74 74 65 72 3e 0d 0a | 20 20 20 20 20 20 20 20 |etter>..| |
|00001ee0| 3c 21 5b 43 44 41 54 41 | 5b 0d 0a 20 20 20 20 20 |<![CDATA|[.. |
|00001ef0| 20 20 20 20 20 76 61 72 | 20 63 6f 6c 73 20 3d 20 | var| cols = |
|00001f00| 5b 5d 3b 0d 0a 20 20 20 | 20 20 20 20 20 0d 0a 20 |[];.. | .. |
|00001f10| 20 20 20 20 20 20 20 20 | 20 76 61 72 20 74 72 65 | | var tre|
|00001f20| 65 63 6f 6c 73 20 3d 20 | 64 6f 63 75 6d 65 6e 74 |ecols = |document|
|00001f30| 2e 67 65 74 41 6e 6f 6e | 79 6d 6f 75 73 45 6c 65 |.getAnon|ymousEle|
|00001f40| 6d 65 6e 74 42 79 41 74 | 74 72 69 62 75 74 65 28 |mentByAt|tribute(|
|00001f50| 74 68 69 73 2c 20 22 61 | 6e 6f 6e 69 64 22 2c 20 |this, "a|nonid", |
|00001f60| 22 74 72 65 65 63 6f 6c | 73 22 29 3b 0d 0a 20 20 |"treecol|s");.. |
|00001f70| 20 20 20 20 20 20 20 20 | 76 61 72 20 63 68 69 6c | |var chil|
|00001f80| 64 20 3d 20 74 72 65 65 | 63 6f 6c 73 2e 66 69 72 |d = tree|cols.fir|
|00001f90| 73 74 43 68 69 6c 64 3b | 0d 0a 20 20 20 20 20 20 |stChild;|.. |
|00001fa0| 20 20 20 20 77 68 69 6c | 65 20 28 63 68 69 6c 64 | whil|e (child|
|00001fb0| 29 20 7b 0d 0a 20 20 20 | 20 20 20 20 20 20 20 20 |) {.. | |
|00001fc0| 20 69 66 20 28 63 68 69 | 6c 64 2e 6c 6f 63 61 6c | if (chi|ld.local|
|00001fd0| 4e 61 6d 65 20 21 3d 20 | 22 73 70 6c 69 74 74 65 |Name != |"splitte|
|00001fe0| 72 22 29 20 7b 0d 0a 20 | 20 20 20 20 20 20 20 20 |r") {.. | |
|00001ff0| 20 20 20 20 20 76 61 72 | 20 6f 62 6a 20 3d 20 7b | var| obj = {|
|00002000| 0d 0a 20 20 20 20 20 20 | 20 20 20 20 20 20 20 20 |.. | |
|00002010| 20 20 6c 61 62 65 6c 3a | 20 63 68 69 6c 64 2e 67 | label:| child.g|
|00002020| 65 74 41 74 74 72 69 62 | 75 74 65 28 22 6c 61 62 |etAttrib|ute("lab|
|00002030| 65 6c 22 29 2c 0d 0a 20 | 20 20 20 20 20 20 20 20 |el"),.. | |
|00002040| 20 20 20 20 20 20 20 61 | 63 63 65 73 73 6b 65 79 | a|ccesskey|
|00002050| 3a 20 63 68 69 6c 64 2e | 67 65 74 41 74 74 72 69 |: child.|getAttri|
|00002060| 62 75 74 65 28 22 61 63 | 63 65 73 73 6b 65 79 22 |bute("ac|cesskey"|
|00002070| 29 2c 0d 0a 20 20 20 20 | 20 20 20 20 20 20 20 20 |),.. | |
|00002080| 20 20 20 20 72 65 73 6f | 75 72 63 65 3a 20 63 68 | reso|urce: ch|
|00002090| 69 6c 64 2e 67 65 74 41 | 74 74 72 69 62 75 74 65 |ild.getA|ttribute|
|000020a0| 28 22 73 6f 72 74 22 29 | 2c 0d 0a 20 20 20 20 20 |("sort")|,.. |
|000020b0| 20 20 20 20 20 20 20 20 | 20 20 20 73 6f 72 74 41 | | sortA|
|000020c0| 63 74 69 76 65 3a 20 63 | 68 69 6c 64 2e 67 65 74 |ctive: c|hild.get|
|000020d0| 41 74 74 72 69 62 75 74 | 65 28 22 73 6f 72 74 41 |Attribut|e("sortA|
|000020e0| 63 74 69 76 65 22 29 20 | 3d 3d 20 22 74 72 75 65 |ctive") |== "true|
|000020f0| 22 2c 0d 0a 20 20 20 20 | 20 20 20 20 20 20 20 20 |",.. | |
|00002100| 20 20 20 20 68 69 64 64 | 65 6e 3a 20 63 68 69 6c | hidd|en: chil|
|00002110| 64 2e 67 65 74 41 74 74 | 72 69 62 75 74 65 28 22 |d.getAtt|ribute("|
|00002120| 68 69 64 64 65 6e 22 29 | 0d 0a 20 20 20 20 20 20 |hidden")|.. |
|00002130| 20 20 20 20 20 20 20 20 | 7d 0d 0a 20 20 20 20 20 | |}.. |
|00002140| 20 20 20 20 20 20 20 20 | 20 63 6f 6c 73 2e 70 75 | | cols.pu|
|00002150| 73 68 28 6f 62 6a 29 3b | 0d 0a 20 20 20 20 20 20 |sh(obj);|.. |
|00002160| 20 20 20 20 20 20 7d 0d | 0a 20 20 20 20 20 20 20 | }.|. |
|00002170| 20 20 20 20 20 63 68 69 | 6c 64 20 3d 20 63 68 69 | chi|ld = chi|
|00002180| 6c 64 2e 6e 65 78 74 53 | 69 62 6c 69 6e 67 3b 0d |ld.nextS|ibling;.|
|00002190| 0a 20 20 20 20 20 20 20 | 20 20 20 7d 0d 0a 0d 0a |. | }....|
|000021a0| 20 20 20 20 20 20 20 20 | 20 20 72 65 74 75 72 6e | | return|
|000021b0| 20 63 6f 6c 73 3b 0d 0a | 20 20 20 20 20 20 20 20 | cols;..| |
|000021c0| 5d 5d 3e 0d 0a 20 20 20 | 20 20 20 20 20 3c 2f 67 |]]>.. | </g|
|000021d0| 65 74 74 65 72 3e 0d 0a | 20 20 20 20 20 20 3c 2f |etter>..| </|
|000021e0| 70 72 6f 70 65 72 74 79 | 3e 0d 0a 20 20 20 20 20 |property|>.. |
|000021f0| 20 0d 0a 20 20 20 20 20 | 20 3c 6d 65 74 68 6f 64 | .. | <method|
|00002200| 20 6e 61 6d 65 3d 22 74 | 6f 67 67 6c 65 43 6f 6c | name="t|oggleCol|
|00002210| 75 6d 6e 56 69 73 69 62 | 69 6c 69 74 79 22 3e 0d |umnVisib|ility">.|
|00002220| 0a 20 20 20 20 20 20 20 | 20 3c 70 61 72 61 6d 65 |. | <parame|
|00002230| 74 65 72 20 6e 61 6d 65 | 3d 22 61 43 6f 6c 75 6d |ter name|="aColum|
|00002240| 6e 52 65 73 6f 75 72 63 | 65 22 2f 3e 0d 0a 20 20 |nResourc|e"/>.. |
|00002250| 20 20 20 20 20 20 3c 62 | 6f 64 79 3e 0d 0a 20 20 | <b|ody>.. |
|00002260| 20 20 20 20 20 20 3c 21 | 5b 43 44 41 54 41 5b 0d | <!|[CDATA[.|
|00002270| 0a 20 20 20 20 20 20 20 | 20 20 20 76 61 72 20 65 |. | var e|
|00002280| 6c 74 20 3d 20 64 6f 63 | 75 6d 65 6e 74 2e 67 65 |lt = doc|ument.ge|
|00002290| 74 41 6e 6f 6e 79 6d 6f | 75 73 45 6c 65 6d 65 6e |tAnonymo|usElemen|
|000022a0| 74 42 79 41 74 74 72 69 | 62 75 74 65 28 74 68 69 |tByAttri|bute(thi|
|000022b0| 73 2c 20 22 73 6f 72 74 | 22 2c 20 61 43 6f 6c 75 |s, "sort|", aColu|
|000022c0| 6d 6e 52 65 73 6f 75 72 | 63 65 29 3b 0d 0a 20 20 |mnResour|ce);.. |
|000022d0| 20 20 20 20 20 20 20 20 | 69 66 20 28 65 6c 74 29 | |if (elt)|
|000022e0| 0d 0a 20 20 20 20 20 20 | 20 20 20 20 20 20 65 6c |.. | el|
|000022f0| 74 2e 73 65 74 41 74 74 | 72 69 62 75 74 65 28 22 |t.setAtt|ribute("|
|00002300| 68 69 64 64 65 6e 22 2c | 20 65 6c 74 2e 67 65 74 |hidden",| elt.get|
|00002310| 41 74 74 72 69 62 75 74 | 65 28 22 68 69 64 64 65 |Attribut|e("hidde|
|00002320| 6e 22 29 20 21 3d 20 22 | 74 72 75 65 22 29 3b 0d |n") != "|true");.|
|00002330| 0a 20 20 20 20 20 20 20 | 20 5d 5d 3e 0d 0a 20 20 |. | ]]>.. |
|00002340| 20 20 20 20 20 20 3c 2f | 62 6f 64 79 3e 0d 0a 20 | </|body>.. |
|00002350| 20 20 20 20 20 3c 2f 6d | 65 74 68 6f 64 3e 20 20 | </m|ethod> |
|00002360| 20 20 20 20 0d 0a 0d 0a | 20 20 20 20 20 20 3c 70 | ....| <p|
|00002370| 72 6f 70 65 72 74 79 20 | 6e 61 6d 65 3d 22 74 72 |roperty |name="tr|
|00002380| 65 65 22 3e 0d 0a 20 20 | 20 20 20 20 20 20 3c 67 |ee">.. | <g|
|00002390| 65 74 74 65 72 3e 3c 21 | 5b 43 44 41 54 41 5b 0d |etter><!|[CDATA[.|
|000023a0| 0a 20 20 20 20 20 20 20 | 20 20 20 72 65 74 75 72 |. | retur|
|000023b0| 6e 20 64 6f 63 75 6d 65 | 6e 74 2e 67 65 74 41 6e |n docume|nt.getAn|
|000023c0| 6f 6e 79 6d 6f 75 73 45 | 6c 65 6d 65 6e 74 42 79 |onymousE|lementBy|
|000023d0| 41 74 74 72 69 62 75 74 | 65 28 74 68 69 73 2c 20 |Attribut|e(this, |
|000023e0| 22 61 6e 6f 6e 69 64 22 | 2c 20 22 62 6f 6f 6b 6d |"anonid"|, "bookm|
|000023f0| 61 72 6b 73 2d 74 72 65 | 65 22 29 3b 0d 0a 20 20 |arks-tre|e");.. |
|00002400| 20 20 20 20 20 20 5d 5d | 3e 3c 2f 67 65 74 74 65 | ]]|></gette|
|00002410| 72 3e 0d 0a 20 20 20 20 | 20 20 3c 2f 70 72 6f 70 |r>.. | </prop|
|00002420| 65 72 74 79 3e 0d 0a 0d | 0a 20 20 20 20 20 20 3c |erty>...|. <|
|00002430| 70 72 6f 70 65 72 74 79 | 20 6e 61 6d 65 3d 22 74 |property| name="t|
|00002440| 72 65 65 42 6f 78 4f 62 | 6a 65 63 74 22 3e 0d 0a |reeBoxOb|ject">..|
|00002450| 20 20 20 20 20 20 20 20 | 3c 67 65 74 74 65 72 3e | |<getter>|
|00002460| 3c 21 5b 43 44 41 54 41 | 5b 0d 0a 20 20 20 20 20 |<![CDATA|[.. |
|00002470| 20 20 20 20 20 72 65 74 | 75 72 6e 20 74 68 69 73 | ret|urn this|
|00002480| 2e 74 72 65 65 2e 62 6f | 78 4f 62 6a 65 63 74 2e |.tree.bo|xObject.|
|00002490| 51 75 65 72 79 49 6e 74 | 65 72 66 61 63 65 28 43 |QueryInt|erface(C|
|000024a0| 6f 6d 70 6f 6e 65 6e 74 | 73 2e 69 6e 74 65 72 66 |omponent|s.interf|
|000024b0| 61 63 65 73 2e 6e 73 49 | 54 72 65 65 42 6f 78 4f |aces.nsI|TreeBoxO|
|000024c0| 62 6a 65 63 74 29 3b 0d | 0a 20 20 20 20 20 20 20 |bject);.|. |
|000024d0| 20 5d 5d 3e 3c 2f 67 65 | 74 74 65 72 3e 0d 0a 20 | ]]></ge|tter>.. |
|000024e0| 20 20 20 20 20 3c 2f 70 | 72 6f 70 65 72 74 79 3e | </p|roperty>|
|000024f0| 0d 0a 0d 0a 20 20 20 20 | 20 20 3c 70 72 6f 70 65 |.... | <prope|
|00002500| 72 74 79 20 6e 61 6d 65 | 3d 22 74 72 65 65 42 75 |rty name|="treeBu|
|00002510| 69 6c 64 65 72 22 3e 0d | 0a 20 20 20 20 20 20 20 |ilder">.|. |
|00002520| 20 3c 67 65 74 74 65 72 | 3e 3c 21 5b 43 44 41 54 | <getter|><![CDAT|
|00002530| 41 5b 0d 0a 20 20 20 20 | 20 20 20 20 20 20 72 65 |A[.. | re|
|00002540| 74 75 72 6e 20 74 68 69 | 73 2e 74 72 65 65 2e 62 |turn thi|s.tree.b|
|00002550| 75 69 6c 64 65 72 2e 51 | 75 65 72 79 49 6e 74 65 |uilder.Q|ueryInte|
|00002560| 72 66 61 63 65 28 43 6f | 6d 70 6f 6e 65 6e 74 73 |rface(Co|mponents|
|00002570| 2e 69 6e 74 65 72 66 61 | 63 65 73 2e 6e 73 49 58 |.interfa|ces.nsIX|
|00002580| 55 4c 54 72 65 65 42 75 | 69 6c 64 65 72 29 3b 0d |ULTreeBu|ilder);.|
|00002590| 0a 20 20 20 20 20 20 20 | 20 5d 5d 3e 3c 2f 67 65 |. | ]]></ge|
|000025a0| 74 74 65 72 3e 0d 0a 20 | 20 20 20 20 20 3c 2f 70 |tter>.. | </p|
|000025b0| 72 6f 70 65 72 74 79 3e | 0d 0a 0d 0a 20 20 20 20 |roperty>|.... |
|000025c0| 20 20 3c 70 72 6f 70 65 | 72 74 79 20 6e 61 6d 65 | <prope|rty name|
|000025d0| 3d 22 74 79 70 65 22 3e | 0d 0a 20 20 20 20 20 20 |="type">|.. |
|000025e0| 20 20 3c 67 65 74 74 65 | 72 3e 3c 21 5b 43 44 41 | <gette|r><![CDA|
|000025f0| 54 41 5b 0d 0a 20 20 20 | 20 20 20 20 20 20 20 69 |TA[.. | i|
|00002600| 66 20 28 21 74 68 69 73 | 2e 5f 74 79 70 65 29 20 |f (!this|._type) |
|00002610| 7b 0d 0a 20 20 20 20 20 | 20 20 20 20 20 20 20 76 |{.. | v|
|00002620| 61 72 20 74 79 70 65 20 | 3d 20 74 68 69 73 2e 67 |ar type |= this.g|
|00002630| 65 74 41 74 74 72 69 62 | 75 74 65 28 22 74 79 70 |etAttrib|ute("typ|
|00002640| 65 22 29 3b 0d 0a 20 20 | 20 20 20 20 20 20 20 20 |e");.. | |
|00002650| 20 20 69 66 20 28 21 74 | 79 70 65 29 0d 0a 20 20 | if (!t|ype).. |
|00002660| 20 20 20 20 20 20 20 20 | 20 20 20 20 74 79 70 65 | | type|
|00002670| 20 3d 20 22 6d 75 6c 74 | 69 2d 63 6f 6c 75 6d 6e | = "mult|i-column|
|00002680| 22 3b 0d 0a 20 20 20 20 | 20 20 20 20 20 20 20 20 |";.. | |
|00002690| 74 68 69 73 2e 5f 74 79 | 70 65 20 3d 20 74 79 70 |this._ty|pe = typ|
|000026a0| 65 3b 0d 0a 20 20 20 20 | 20 20 20 20 20 20 7d 0d |e;.. | }.|
|000026b0| 0a 20 20 20 20 20 20 20 | 20 20 20 72 65 74 75 72 |. | retur|
|000026c0| 6e 20 74 68 69 73 2e 5f | 74 79 70 65 3b 0d 0a 20 |n this._|type;.. |
|000026d0| 20 20 20 20 20 20 20 5d | 5d 3e 3c 2f 67 65 74 74 | ]|]></gett|
|000026e0| 65 72 3e 0d 0a 20 20 20 | 20 20 20 3c 2f 70 72 6f |er>.. | </pro|
|000026f0| 70 65 72 74 79 3e 0d 0a | 0d 0a 20 20 20 20 20 20 |perty>..|.. |
|00002700| 3c 70 72 6f 70 65 72 74 | 79 20 6e 61 6d 65 3d 22 |<propert|y name="|
|00002710| 63 75 72 72 65 6e 74 49 | 6e 64 65 78 22 3e 0d 0a |currentI|ndex">..|
|00002720| 20 20 20 20 20 20 20 20 | 3c 67 65 74 74 65 72 3e | |<getter>|
|00002730| 3c 21 5b 43 44 41 54 41 | 5b 0d 0a 20 20 20 20 20 |<![CDATA|[.. |
|00002740| 20 20 20 20 20 72 65 74 | 75 72 6e 20 74 68 69 73 | ret|urn this|
|00002750| 2e 74 72 65 65 42 6f 78 | 4f 62 6a 65 63 74 2e 73 |.treeBox|Object.s|
|00002760| 65 6c 65 63 74 69 6f 6e | 2e 63 75 72 72 65 6e 74 |election|.current|
|00002770| 49 6e 64 65 78 3b 0d 0a | 20 20 20 20 20 20 20 20 |Index;..| |
|00002780| 5d 5d 3e 3c 2f 67 65 74 | 74 65 72 3e 0d 0a 20 20 |]]></get|ter>.. |
|00002790| 20 20 20 20 3c 2f 70 72 | 6f 70 65 72 74 79 3e 0d | </pr|operty>.|
|000027a0| 0a 20 20 20 20 0d 0a 20 | 20 20 20 20 20 3c 70 72 |. .. | <pr|
|000027b0| 6f 70 65 72 74 79 20 6e | 61 6d 65 3d 22 63 75 72 |operty n|ame="cur|
|000027c0| 72 65 6e 74 52 65 73 6f | 75 72 63 65 22 3e 0d 0a |rentReso|urce">..|
|000027d0| 20 20 20 20 20 20 20 20 | 3c 67 65 74 74 65 72 3e | |<getter>|
|000027e0| 3c 21 5b 43 44 41 54 41 | 5b 0d 0a 20 20 20 20 20 |<![CDATA|[.. |
|000027f0| 20 20 20 20 20 72 65 74 | 75 72 6e 20 74 68 69 73 | ret|urn this|
|00002800| 2e 74 72 65 65 42 75 69 | 6c 64 65 72 2e 67 65 74 |.treeBui|lder.get|
|00002810| 52 65 73 6f 75 72 63 65 | 41 74 49 6e 64 65 78 28 |Resource|AtIndex(|
|00002820| 74 68 69 73 2e 63 75 72 | 72 65 6e 74 49 6e 64 65 |this.cur|rentInde|
|00002830| 78 29 3b 0d 0a 20 20 20 | 20 20 20 20 20 5d 5d 3e |x);.. | ]]>|
|00002840| 3c 2f 67 65 74 74 65 72 | 3e 0d 0a 20 20 20 20 20 |</getter|>.. |
|00002850| 20 3c 2f 70 72 6f 70 65 | 72 74 79 3e 0d 0a 0d 0a | </prope|rty>....|
|00002860| 20 20 20 20 20 20 3c 6d | 65 74 68 6f 64 20 6e 61 | <m|ethod na|
|00002870| 6d 65 3d 22 67 65 74 52 | 6f 77 52 65 73 6f 75 72 |me="getR|owResour|
|00002880| 63 65 22 3e 0d 0a 20 20 | 20 20 20 20 20 20 3c 70 |ce">.. | <p|
|00002890| 61 72 61 6d 65 74 65 72 | 20 6e 61 6d 65 3d 22 61 |arameter| name="a|
|000028a0| 52 6f 77 22 2f 3e 0d 0a | 20 20 20 20 20 20 20 20 |Row"/>..| |
|000028b0| 3c 62 6f 64 79 3e 3c 21 | 5b 43 44 41 54 41 5b 0d |<body><!|[CDATA[.|
|000028c0| 0a 20 20 20 20 20 20 20 | 20 20 20 69 66 20 28 61 |. | if (a|
|000028d0| 52 6f 77 20 21 3d 20 2d | 31 29 0d 0a 20 20 20 20 |Row != -|1).. |
|000028e0| 20 20 20 20 20 20 20 20 | 72 65 74 75 72 6e 20 74 | |return t|
|000028f0| 68 69 73 2e 74 72 65 65 | 42 75 69 6c 64 65 72 2e |his.tree|Builder.|
|00002900| 67 65 74 52 65 73 6f 75 | 72 63 65 41 74 49 6e 64 |getResou|rceAtInd|
|00002910| 65 78 28 61 52 6f 77 29 | 3b 0d 0a 20 20 20 20 20 |ex(aRow)|;.. |
|00002920| 20 20 20 20 20 65 6c 73 | 65 0d 0a 20 20 20 20 20 | els|e.. |
|00002930| 20 20 20 20 20 20 20 72 | 65 74 75 72 6e 20 74 68 | r|eturn th|
|00002940| 69 73 2e 67 65 74 52 6f | 6f 74 52 65 73 6f 75 72 |is.getRo|otResour|
|00002950| 63 65 28 29 3b 0d 0a 20 | 20 20 20 20 20 20 20 5d |ce();.. | ]|
|00002960| 5d 3e 3c 2f 62 6f 64 79 | 3e 0d 0a 20 20 20 20 20 |]></body|>.. |
|00002970| 20 3c 2f 6d 65 74 68 6f | 64 3e 0d 0a 0d 0a 20 20 | </metho|d>.... |
|00002980| 20 20 20 20 3c 6d 65 74 | 68 6f 64 20 6e 61 6d 65 | <met|hod name|
|00002990| 3d 22 67 65 74 50 61 72 | 65 6e 74 52 65 73 6f 75 |="getPar|entResou|
|000029a0| 72 63 65 22 3e 0d 0a 20 | 20 20 20 20 20 20 20 3c |rce">.. | <|
|000029b0| 70 61 72 61 6d 65 74 65 | 72 20 6e 61 6d 65 3d 22 |paramete|r name="|
|000029c0| 61 52 6f 77 22 2f 3e 0d | 0a 20 20 20 20 20 20 20 |aRow"/>.|. |
|000029d0| 20 3c 62 6f 64 79 3e 3c | 21 5b 43 44 41 54 41 5b | <body><|![CDATA[|
|000029e0| 0d 0a 20 20 20 20 20 20 | 20 20 20 20 69 66 20 28 |.. | if (|
|000029f0| 61 52 6f 77 20 21 3d 20 | 2d 31 29 20 7b 0d 0a 20 |aRow != |-1) {.. |
|00002a00| 20 20 20 20 20 20 20 20 | 20 20 20 76 61 72 20 70 | | var p|
|00002a10| 61 72 65 6e 74 49 6e 64 | 65 78 20 3d 20 74 68 69 |arentInd|ex = thi|
|00002a20| 73 2e 74 72 65 65 42 6f | 78 4f 62 6a 65 63 74 2e |s.treeBo|xObject.|
|00002a30| 76 69 65 77 2e 67 65 74 | 50 61 72 65 6e 74 49 6e |view.get|ParentIn|
|00002a40| 64 65 78 28 61 52 6f 77 | 29 3b 0d 0a 20 20 20 20 |dex(aRow|);.. |
|00002a50| 20 20 20 20 20 20 20 20 | 72 65 74 75 72 6e 20 74 | |return t|
|00002a60| 68 69 73 2e 67 65 74 52 | 6f 77 52 65 73 6f 75 72 |his.getR|owResour|
|00002a70| 63 65 28 70 61 72 65 6e | 74 49 6e 64 65 78 29 3b |ce(paren|tIndex);|
|00002a80| 0d 0a 20 20 20 20 20 20 | 20 20 20 20 7d 0d 0a 20 |.. | }.. |
|00002a90| 20 20 20 20 20 20 20 20 | 20 72 65 74 75 72 6e 20 | | return |
|00002aa0| 74 68 69 73 2e 67 65 74 | 52 6f 6f 74 52 65 73 6f |this.get|RootReso|
|00002ab0| 75 72 63 65 28 29 3b 20 | 2f 2f 20 61 73 73 75 6d |urce(); |// assum|
|00002ac0| 65 20 69 74 73 20 70 61 | 72 65 6e 74 20 69 73 20 |e its pa|rent is |
|00002ad0| 74 68 65 20 72 6f 6f 74 | 0d 0a 20 20 20 20 20 20 |the root|.. |
|00002ae0| 20 20 5d 5d 3e 3c 2f 62 | 6f 64 79 3e 0d 0a 20 20 | ]]></b|ody>.. |
|00002af0| 20 20 20 20 3c 2f 6d 65 | 74 68 6f 64 3e 0d 0a 0d | </me|thod>...|
|00002b00| 0a 20 20 20 20 20 20 3c | 6d 65 74 68 6f 64 20 6e |. <|method n|
|00002b10| 61 6d 65 3d 22 67 65 74 | 52 6f 6f 74 52 65 73 6f |ame="get|RootReso|
|00002b20| 75 72 63 65 22 3e 0d 0a | 20 20 20 20 20 20 20 20 |urce">..| |
|00002b30| 3c 62 6f 64 79 3e 3c 21 | 5b 43 44 41 54 41 5b 0d |<body><!|[CDATA[.|
|00002b40| 0a 20 20 20 20 20 20 20 | 20 20 20 76 61 72 20 74 |. | var t|
|00002b50| 72 65 65 20 3d 20 64 6f | 63 75 6d 65 6e 74 2e 67 |ree = do|cument.g|
|00002b60| 65 74 41 6e 6f 6e 79 6d | 6f 75 73 45 6c 65 6d 65 |etAnonym|ousEleme|
|00002b70| 6e 74 42 79 41 74 74 72 | 69 62 75 74 65 28 74 68 |ntByAttr|ibute(th|
|00002b80| 69 73 2c 20 22 61 6e 6f | 6e 69 64 22 2c 20 22 62 |is, "ano|nid", "b|
|00002b90| 6f 6f 6b 6d 61 72 6b 73 | 2d 74 72 65 65 22 29 3b |ookmarks|-tree");|
|00002ba0| 0d 0a 20 20 20 20 20 20 | 20 20 20 20 72 65 74 75 |.. | retu|
|00002bb0| 72 6e 20 52 44 46 2e 47 | 65 74 52 65 73 6f 75 72 |rn RDF.G|etResour|
|00002bc0| 63 65 28 74 72 65 65 2e | 72 65 66 29 3b 0d 0a 20 |ce(tree.|ref);.. |
|00002bd0| 20 20 20 20 20 20 20 5d | 5d 3e 3c 2f 62 6f 64 79 | ]|]></body|
|00002be0| 3e 0d 0a 20 20 20 20 20 | 20 3c 2f 6d 65 74 68 6f |>.. | </metho|
|00002bf0| 64 3e 0d 0a 0d 0a 20 20 | 20 20 20 20 3c 6d 65 74 |d>.... | <met|
|00002c00| 68 6f 64 20 6e 61 6d 65 | 3d 22 73 65 6c 65 63 74 |hod name|="select|
|00002c10| 52 65 73 6f 75 72 63 65 | 22 3e 0d 0a 20 20 20 20 |Resource|">.. |
|00002c20| 20 20 20 20 3c 70 61 72 | 61 6d 65 74 65 72 20 6e | <par|ameter n|
|00002c30| 61 6d 65 3d 22 61 52 65 | 73 6f 75 72 63 65 22 2f |ame="aRe|source"/|
|00002c40| 3e 0d 0a 20 20 20 20 20 | 20 20 20 3c 62 6f 64 79 |>.. | <body|
|00002c50| 3e 3c 21 5b 43 44 41 54 | 41 5b 0d 0a 20 20 20 20 |><![CDAT|A[.. |
|00002c60| 20 20 20 20 20 20 76 61 | 72 20 69 6e 64 65 78 20 | va|r index |
|00002c70| 3d 20 74 68 69 73 2e 74 | 72 65 65 42 75 69 6c 64 |= this.t|reeBuild|
|00002c80| 65 72 2e 67 65 74 49 6e | 64 65 78 4f 66 52 65 73 |er.getIn|dexOfRes|
|00002c90| 6f 75 72 63 65 28 61 52 | 65 73 6f 75 72 63 65 29 |ource(aR|esource)|
|00002ca0| 3b 0d 0a 20 20 20 20 20 | 20 20 20 20 20 69 66 20 |;.. | if |
|00002cb0| 28 69 6e 64 65 78 20 21 | 3d 20 2d 31 29 20 7b 0d |(index !|= -1) {.|
|00002cc0| 0a 20 20 20 20 20 20 20 | 20 20 20 20 20 69 66 20 |. | if |
|00002cd0| 28 21 74 68 69 73 2e 74 | 72 65 65 42 6f 78 4f 62 |(!this.t|reeBoxOb|
|00002ce0| 6a 65 63 74 2e 73 65 6c | 65 63 74 69 6f 6e 2e 69 |ject.sel|ection.i|
|00002cf0| 73 53 65 6c 65 63 74 65 | 64 28 69 6e 64 65 78 29 |sSelecte|d(index)|
|00002d00| 29 0d 0a 20 20 20 20 20 | 20 20 20 20 20 20 20 20 |).. | |
|00002d10| 20 74 68 69 73 2e 74 72 | 65 65 42 6f 78 4f 62 6a | this.tr|eeBoxObj|
|00002d20| 65 63 74 2e 73 65 6c 65 | 63 74 69 6f 6e 2e 74 6f |ect.sele|ction.to|
|00002d30| 67 67 6c 65 53 65 6c 65 | 63 74 28 69 6e 64 65 78 |ggleSele|ct(index|
|00002d40| 29 3b 0d 0a 20 20 20 20 | 20 20 20 20 20 20 20 20 |);.. | |
|00002d50| 72 65 74 75 72 6e 3b 0d | 0a 20 20 20 20 20 20 20 |return;.|. |
|00002d60| 20 20 20 7d 0d 0a 20 20 | 20 20 20 20 20 20 20 0d | }.. | .|
|00002d70| 0a 20 20 20 20 20 20 20 | 20 20 20 76 61 72 20 63 |. | var c|
|00002d80| 68 61 69 6e 20 3d 20 42 | 4d 53 56 43 2e 67 65 74 |hain = B|MSVC.get|
|00002d90| 50 61 72 65 6e 74 43 68 | 61 69 6e 28 61 52 65 73 |ParentCh|ain(aRes|
|00002da0| 6f 75 72 63 65 29 3b 0d | 0a 20 20 20 20 20 20 20 |ource);.|. |
|00002db0| 20 20 20 2f 2f 64 75 6d | 70 28 22 43 68 61 69 6e | //dum|p("Chain|
|00002dc0| 3a 22 2b 63 68 61 69 6e | 2e 6c 65 6e 67 74 68 2b |:"+chain|.length+|
|00002dd0| 22 5c 6e 22 29 3b 0d 0a | 20 20 20 20 20 20 20 20 |"\n");..| |
|00002de0| 20 20 66 6f 72 20 28 76 | 61 72 20 69 3d 30 3b 20 | for (v|ar i=0; |
|00002df0| 69 3c 63 68 61 69 6e 2e | 6c 65 6e 67 74 68 3b 20 |i<chain.|length; |
|00002e00| 69 2b 2b 29 20 7b 0d 0a | 20 20 20 20 20 20 20 20 |i++) {..| |
|00002e10| 20 20 20 20 76 61 72 20 | 72 50 61 72 65 6e 74 20 | var |rParent |
|00002e20| 3d 20 63 68 61 69 6e 2e | 71 75 65 72 79 45 6c 65 |= chain.|queryEle|
|00002e30| 6d 65 6e 74 41 74 28 69 | 2c 20 6b 52 44 46 52 53 |mentAt(i|, kRDFRS|
|00002e40| 43 49 49 44 29 3b 0d 0a | 20 20 20 20 20 20 20 20 |CIID);..| |
|00002e50| 20 20 20 20 69 6e 64 65 | 78 20 3d 20 74 68 69 73 | inde|x = this|
|00002e60| 2e 74 72 65 65 42 75 69 | 6c 64 65 72 2e 67 65 74 |.treeBui|lder.get|
|00002e70| 49 6e 64 65 78 4f 66 52 | 65 73 6f 75 72 63 65 28 |IndexOfR|esource(|
|00002e80| 72 50 61 72 65 6e 74 29 | 3b 0d 0a 20 20 20 20 20 |rParent)|;.. |
|00002e90| 20 20 20 20 20 20 20 2f | 2f 64 75 6d 70 28 69 2b | /|/dump(i+|
|00002ea0| 22 3a 22 2b 42 6f 6f 6b | 6d 61 72 6b 73 55 74 69 |":"+Book|marksUti|
|00002eb0| 6c 73 2e 67 65 74 50 72 | 6f 70 65 72 74 79 28 72 |ls.getPr|operty(r|
|00002ec0| 50 61 72 65 6e 74 2c 20 | 4e 43 5f 4e 53 2b 22 4e |Parent, |NC_NS+"N|
|00002ed0| 61 6d 65 22 29 2b 22 2c | 20 69 6e 64 65 78 3a 22 |ame")+",| index:"|
|00002ee0| 2b 69 6e 64 65 78 2b 22 | 5c 6e 22 29 3b 0d 0a 20 |+index+"|\n");.. |
|00002ef0| 20 20 20 20 20 20 20 20 | 20 20 20 69 66 20 28 69 | | if (i|
|00002f00| 6e 64 65 78 20 3d 3d 20 | 2d 31 29 0d 0a 20 20 20 |ndex == |-1).. |
|00002f10| 20 20 20 20 20 20 20 20 | 20 20 20 63 6f 6e 74 69 | | conti|
|00002f20| 6e 75 65 3b 0d 0a 0d 0a | 20 20 20 20 20 20 20 20 |nue;....| |
|00002f30| 20 20 20 20 69 66 20 28 | 21 74 68 69 73 2e 74 72 | if (|!this.tr|
|00002f40| 65 65 42 6f 78 4f 62 6a | 65 63 74 2e 76 69 65 77 |eeBoxObj|ect.view|
|00002f50| 2e 69 73 43 6f 6e 74 61 | 69 6e 65 72 4f 70 65 6e |.isConta|inerOpen|
|00002f60| 28 69 6e 64 65 78 29 29 | 0d 0a 20 20 20 20 20 20 |(index))|.. |
|00002f70| 20 20 20 20 20 20 20 20 | 74 68 69 73 2e 74 72 65 | |this.tre|
|00002f80| 65 42 6f 78 4f 62 6a 65 | 63 74 2e 76 69 65 77 2e |eBoxObje|ct.view.|
|00002f90| 74 6f 67 67 6c 65 4f 70 | 65 6e 53 74 61 74 65 28 |toggleOp|enState(|
|00002fa0| 69 6e 64 65 78 29 3b 0d | 0a 20 20 20 20 20 20 20 |index);.|. |
|00002fb0| 20 20 20 7d 0d 0a 20 20 | 20 20 20 20 20 20 20 20 | }.. | |
|00002fc0| 69 66 20 28 69 6e 64 65 | 78 20 3d 3d 20 2d 31 29 |if (inde|x == -1)|
|00002fd0| 0d 0a 20 20 20 20 20 20 | 20 20 20 20 20 20 72 65 |.. | re|
|00002fe0| 74 75 72 6e 3b 0d 0a 0d | 0a 20 20 20 20 20 20 20 |turn;...|. |
|00002ff0| 20 20 20 69 6e 64 65 78 | 20 3d 20 74 68 69 73 2e | index| = this.|
|00003000| 74 72 65 65 42 75 69 6c | 64 65 72 2e 67 65 74 49 |treeBuil|der.getI|
|00003010| 6e 64 65 78 4f 66 52 65 | 73 6f 75 72 63 65 28 61 |ndexOfRe|source(a|
|00003020| 52 65 73 6f 75 72 63 65 | 29 3b 0d 0a 20 20 20 20 |Resource|);.. |
|00003030| 20 20 20 20 20 20 69 66 | 20 28 69 6e 64 65 78 20 | if| (index |
|00003040| 21 3d 20 2d 31 29 0d 0a | 20 20 20 20 20 20 20 20 |!= -1)..| |
|00003050| 20 20 20 20 74 68 69 73 | 2e 74 72 65 65 42 6f 78 | this|.treeBox|
|00003060| 4f 62 6a 65 63 74 2e 73 | 65 6c 65 63 74 69 6f 6e |Object.s|election|
|00003070| 2e 74 6f 67 67 6c 65 53 | 65 6c 65 63 74 28 69 6e |.toggleS|elect(in|
|00003080| 64 65 78 29 3b 0d 0a 20 | 20 20 20 20 20 20 20 5d |dex);.. | ]|
|00003090| 5d 3e 3c 2f 62 6f 64 79 | 3e 0d 0a 20 20 20 20 20 |]></body|>.. |
|000030a0| 20 3c 2f 6d 65 74 68 6f | 64 3e 0d 0a 0d 0a 20 20 | </metho|d>.... |
|000030b0| 20 20 20 20 3c 6d 65 74 | 68 6f 64 20 6e 61 6d 65 | <met|hod name|
|000030c0| 3d 22 66 6f 63 75 73 22 | 3e 0d 0a 20 20 20 20 20 |="focus"|>.. |
|000030d0| 20 20 20 3c 62 6f 64 79 | 3e 0d 0a 20 20 20 20 20 | <body|>.. |
|000030e0| 20 20 20 20 20 74 68 69 | 73 2e 74 72 65 65 2e 66 | thi|s.tree.f|
|000030f0| 6f 63 75 73 28 29 3b 0d | 0a 20 20 20 20 20 20 20 |ocus();.|. |
|00003100| 20 3c 2f 62 6f 64 79 3e | 0d 0a 20 20 20 20 20 20 | </body>|.. |
|00003110| 3c 2f 6d 65 74 68 6f 64 | 3e 0d 0a 0d 0a 20 20 20 |</method|>.... |
|00003120| 20 20 20 3c 66 69 65 6c | 64 20 6e 61 6d 65 3d 22 | <fiel|d name="|
|00003130| 5f 73 65 6c 65 63 74 69 | 6f 6e 22 3e 6e 75 6c 6c |_selecti|on">null|
|00003140| 3c 2f 66 69 65 6c 64 3e | 0d 0a 20 20 20 20 20 20 |</field>|.. |
|00003150| 3c 66 69 65 6c 64 20 6e | 61 6d 65 3d 22 5f 74 61 |<field n|ame="_ta|
|00003160| 72 67 65 74 22 3e 20 20 | 20 6e 75 6c 6c 3c 2f 66 |rget"> | null</f|
|00003170| 69 65 6c 64 3e 0d 0a 0d | 0a 20 20 20 20 20 20 3c |ield>...|. <|
|00003180| 6d 65 74 68 6f 64 20 6e | 61 6d 65 3d 22 67 65 74 |method n|ame="get|
|00003190| 54 72 65 65 53 65 6c 65 | 63 74 69 6f 6e 22 3e 0d |TreeSele|ction">.|
|000031a0| 0a 20 20 20 20 20 20 20 | 20 3c 62 6f 64 79 3e 3c |. | <body><|
|000031b0| 21 5b 43 44 41 54 41 5b | 0d 0a 20 20 20 20 20 20 |![CDATA[|.. |
|000031c0| 20 20 20 20 76 61 72 20 | 73 65 6c 65 63 74 69 6f | var |selectio|
|000031d0| 6e 20 20 20 20 20 20 20 | 20 3d 20 7b 7d 3b 0d 0a |n | = {};..|
|000031e0| 20 20 20 20 20 20 20 20 | 20 20 73 65 6c 65 63 74 | | select|
|000031f0| 69 6f 6e 2e 69 74 65 6d | 20 20 20 20 20 20 20 3d |ion.item| =|
|00003200| 20 5b 5d 3b 0d 0a 20 20 | 20 20 20 20 20 20 20 20 | [];.. | |
|00003210| 73 65 6c 65 63 74 69 6f | 6e 2e 70 61 72 65 6e 74 |selectio|n.parent|
|00003220| 20 20 20 20 20 3d 20 5b | 5d 3b 0d 0a 20 20 20 20 | = [|];.. |
|00003230| 20 20 20 20 20 20 73 65 | 6c 65 63 74 69 6f 6e 2e | se|lection.|
|00003240| 69 73 45 78 70 61 6e 64 | 65 64 20 3d 20 5b 5d 3b |isExpand|ed = [];|
|00003250| 0d 0a 20 20 20 20 20 20 | 20 20 20 20 76 61 72 20 |.. | var |
|00003260| 72 61 6e 67 65 43 6f 75 | 6e 74 20 3d 20 74 68 69 |rangeCou|nt = thi|
|00003270| 73 2e 74 72 65 65 42 6f | 78 4f 62 6a 65 63 74 2e |s.treeBo|xObject.|
|00003280| 73 65 6c 65 63 74 69 6f | 6e 2e 67 65 74 52 61 6e |selectio|n.getRan|
|00003290| 67 65 43 6f 75 6e 74 28 | 29 3b 0d 0a 20 20 20 20 |geCount(|);.. |
|000032a0| 20 20 20 20 20 20 2f 2f | 20 77 6f 72 6b 61 72 6f | //| workaro|
|000032b0| 75 6e 64 20 66 6f 72 20 | 62 75 67 20 31 37 31 35 |und for |bug 1715|
|000032c0| 34 37 3a 20 69 66 20 72 | 6f 77 43 6f 75 6e 74 3d |47: if r|owCount=|
|000032d0| 3d 30 2c 20 72 61 6e 67 | 65 43 6f 75 6e 74 3d 3d |=0, rang|eCount==|
|000032e0| 31 0d 0a 20 20 20 20 20 | 20 20 20 20 20 69 66 20 |1.. | if |
|000032f0| 28 74 68 69 73 2e 74 72 | 65 65 42 75 69 6c 64 65 |(this.tr|eeBuilde|
|00003300| 72 2e 72 6f 77 43 6f 75 | 6e 74 20 3e 20 30 29 0d |r.rowCou|nt > 0).|
|00003310| 0a 20 20 20 20 20 20 20 | 20 20 20 66 6f 72 20 28 |. | for (|
|00003320| 76 61 72 20 6b 20 3d 20 | 30 3b 20 6b 20 3c 20 72 |var k = |0; k < r|
|00003330| 61 6e 67 65 43 6f 75 6e | 74 3b 20 2b 2b 6b 29 20 |angeCoun|t; ++k) |
|00003340| 7b 0d 0a 20 20 20 20 20 | 20 20 20 20 20 20 20 76 |{.. | v|
|00003350| 61 72 20 72 61 6e 67 65 | 4d 69 6e 20 3d 20 7b 7d |ar range|Min = {}|
|00003360| 3b 0d 0a 20 20 20 20 20 | 20 20 20 20 20 20 20 76 |;.. | v|
|00003370| 61 72 20 72 61 6e 67 65 | 4d 61 78 20 3d 20 7b 7d |ar range|Max = {}|
|00003380| 3b 0d 0a 20 20 20 20 20 | 20 20 20 20 20 20 20 74 |;.. | t|
|00003390| 68 69 73 2e 74 72 65 65 | 42 6f 78 4f 62 6a 65 63 |his.tree|BoxObjec|
|000033a0| 74 2e 73 65 6c 65 63 74 | 69 6f 6e 2e 67 65 74 52 |t.select|ion.getR|
|000033b0| 61 6e 67 65 41 74 28 6b | 2c 20 72 61 6e 67 65 4d |angeAt(k|, rangeM|
|000033c0| 69 6e 2c 20 72 61 6e 67 | 65 4d 61 78 29 3b 0d 0a |in, rang|eMax);..|
|000033d0| 20 20 20 20 20 20 20 20 | 20 20 20 20 66 6f 72 20 | | for |
|000033e0| 28 76 61 72 20 69 20 3d | 20 72 61 6e 67 65 4d 69 |(var i =| rangeMi|
|000033f0| 6e 2e 76 61 6c 75 65 3b | 20 69 20 3c 3d 20 72 61 |n.value;| i <= ra|
|00003400| 6e 67 65 4d 61 78 2e 76 | 61 6c 75 65 3b 20 2b 2b |ngeMax.v|alue; ++|
|00003410| 69 29 20 7b 0d 0a 20 20 | 20 20 20 20 20 20 20 20 |i) {.. | |
|00003420| 20 20 20 20 76 61 72 20 | 73 65 6c 65 63 74 65 64 | var |selected|
|00003430| 49 74 65 6d 20 20 20 3d | 20 74 68 69 73 2e 67 65 |Item =| this.ge|
|00003440| 74 52 6f 77 52 65 73 6f | 75 72 63 65 28 69 29 3b |tRowReso|urce(i);|
|00003450| 0d 0a 20 20 20 20 20 20 | 20 20 20 20 20 20 20 20 |.. | |
|00003460| 76 61 72 20 73 65 6c 65 | 63 74 65 64 50 61 72 65 |var sele|ctedPare|
|00003470| 6e 74 20 3d 20 74 68 69 | 73 2e 67 65 74 50 61 72 |nt = thi|s.getPar|
|00003480| 65 6e 74 52 65 73 6f 75 | 72 63 65 28 69 29 3b 0d |entResou|rce(i);.|
|00003490| 0a 20 20 20 20 20 20 20 | 20 20 20 20 20 20 20 76 |. | v|
|000034a0| 61 72 20 69 73 45 78 70 | 61 6e 64 65 64 20 20 20 |ar isExp|anded |
|000034b0| 20 20 3d 20 74 68 69 73 | 2e 74 72 65 65 42 6f 78 | = this|.treeBox|
|000034c0| 4f 62 6a 65 63 74 2e 76 | 69 65 77 2e 69 73 43 6f |Object.v|iew.isCo|
|000034d0| 6e 74 61 69 6e 65 72 4f | 70 65 6e 28 69 29 3b 0d |ntainerO|pen(i);.|
|000034e0| 0a 20 20 20 20 20 20 20 | 20 20 20 20 20 20 20 73 |. | s|
|000034f0| 65 6c 65 63 74 69 6f 6e | 2e 69 74 65 6d 20 20 2e |election|.item .|
|00003500| 70 75 73 68 28 73 65 6c | 65 63 74 65 64 49 74 65 |push(sel|ectedIte|
|00003510| 6d 29 3b 0d 0a 20 20 20 | 20 20 20 20 20 20 20 20 |m);.. | |
|00003520| 20 20 20 73 65 6c 65 63 | 74 69 6f 6e 2e 70 61 72 | selec|tion.par|
|00003530| 65 6e 74 2e 70 75 73 68 | 28 73 65 6c 65 63 74 65 |ent.push|(selecte|
|00003540| 64 50 61 72 65 6e 74 29 | 3b 0d 0a 20 20 20 20 20 |dParent)|;.. |
|00003550| 20 20 20 20 20 20 20 20 | 20 73 65 6c 65 63 74 69 | | selecti|
|00003560| 6f 6e 2e 69 73 45 78 70 | 61 6e 64 65 64 2e 70 75 |on.isExp|anded.pu|
|00003570| 73 68 28 69 73 45 78 70 | 61 6e 64 65 64 29 3b 0d |sh(isExp|anded);.|
|00003580| 0a 20 20 20 20 20 20 20 | 20 20 20 20 20 7d 0d 0a |. | }..|
|00003590| 20 20 20 20 20 20 20 20 | 20 20 7d 0d 0a 20 20 20 | | }.. |
|000035a0| 20 20 20 20 20 20 20 73 | 65 6c 65 63 74 69 6f 6e | s|election|
|000035b0| 2e 6c 65 6e 67 74 68 20 | 3d 20 73 65 6c 65 63 74 |.length |= select|
|000035c0| 69 6f 6e 2e 69 74 65 6d | 2e 6c 65 6e 67 74 68 3b |ion.item|.length;|
|000035d0| 0d 0a 20 20 20 20 20 20 | 20 20 20 20 42 6f 6f 6b |.. | Book|
|000035e0| 6d 61 72 6b 73 55 74 69 | 6c 73 2e 63 68 65 63 6b |marksUti|ls.check|
|000035f0| 53 65 6c 65 63 74 69 6f | 6e 28 73 65 6c 65 63 74 |Selectio|n(select|
|00003600| 69 6f 6e 29 3b 0d 0a 20 | 20 20 20 20 20 20 20 20 |ion);.. | |
|00003610| 20 72 65 74 75 72 6e 20 | 73 65 6c 65 63 74 69 6f | return |selectio|
|00003620| 6e 3b 0d 0a 20 20 20 20 | 20 20 20 20 5d 5d 3e 3c |n;.. | ]]><|
|00003630| 2f 62 6f 64 79 3e 0d 0a | 20 20 20 20 20 20 3c 2f |/body>..| </|
|00003640| 6d 65 74 68 6f 64 3e 0d | 0a 0d 0a 20 20 20 20 20 |method>.|... |
|00003650| 20 3c 6d 65 74 68 6f 64 | 20 6e 61 6d 65 3d 22 67 | <method| name="g|
|00003660| 65 74 54 72 65 65 54 61 | 72 67 65 74 22 3e 0d 0a |etTreeTa|rget">..|
|00003670| 20 20 20 20 20 20 20 20 | 3c 70 61 72 61 6d 65 74 | |<paramet|
|00003680| 65 72 20 6e 61 6d 65 3d | 22 61 49 74 65 6d 22 2f |er name=|"aItem"/|
|00003690| 3e 0d 0a 20 20 20 20 20 | 20 20 20 3c 70 61 72 61 |>.. | <para|
|000036a0| 6d 65 74 65 72 20 6e 61 | 6d 65 3d 22 61 50 61 72 |meter na|me="aPar|
|000036b0| 65 6e 74 22 2f 3e 0d 0a | 20 20 20 20 20 20 20 20 |ent"/>..| |
|000036c0| 3c 70 61 72 61 6d 65 74 | 65 72 20 6e 61 6d 65 3d |<paramet|er name=|
|000036d0| 22 61 4f 72 69 65 6e 74 | 61 74 69 6f 6e 22 2f 3e |"aOrient|ation"/>|
|000036e0| 0d 0a 20 20 20 20 20 20 | 20 20 3c 62 6f 64 79 3e |.. | <body>|
|000036f0| 3c 21 5b 43 44 41 54 41 | 5b 0d 0a 0d 0a 20 20 20 |<![CDATA|[.... |
|00003700| 20 20 20 20 20 20 20 69 | 66 20 28 21 61 50 61 72 | i|f (!aPar|
|00003710| 65 6e 74 20 7c 7c 20 61 | 50 61 72 65 6e 74 2e 56 |ent || a|Parent.V|
|00003720| 61 6c 75 65 20 3d 3d 20 | 22 4e 43 3a 42 6f 6f 6b |alue == |"NC:Book|
|00003730| 6d 61 72 6b 73 54 6f 70 | 52 6f 6f 74 22 29 0d 0a |marksTop|Root")..|
|00003740| 20 20 20 20 20 20 20 20 | 20 20 20 20 72 65 74 75 | | retu|
|00003750| 72 6e 20 42 6f 6f 6b 6d | 61 72 6b 73 55 74 69 6c |rn Bookm|arksUtil|
|00003760| 73 2e 67 65 74 54 61 72 | 67 65 74 46 72 6f 6d 46 |s.getTar|getFromF|
|00003770| 6f 6c 64 65 72 28 52 44 | 46 2e 47 65 74 52 65 73 |older(RD|F.GetRes|
|00003780| 6f 75 72 63 65 28 22 4e | 43 3a 42 6f 6f 6b 6d 61 |ource("N|C:Bookma|
|00003790| 72 6b 73 52 6f 6f 74 22 | 29 29 0d 0a 0d 0a 20 20 |rksRoot"|)).... |
|000037a0| 20 20 20 20 20 20 20 20 | 69 66 20 28 61 4f 72 69 | |if (aOri|
|000037b0| 65 6e 74 61 74 69 6f 6e | 20 3d 3d 20 42 6f 6f 6b |entation| == Book|
|000037c0| 6d 61 72 6b 73 55 74 69 | 6c 73 2e 44 52 4f 50 5f |marksUti|ls.DROP_|
|000037d0| 4f 4e 29 0d 0a 20 20 20 | 20 20 20 20 20 20 20 20 |ON).. | |
|000037e0| 20 72 65 74 75 72 6e 20 | 42 6f 6f 6b 6d 61 72 6b | return |Bookmark|
|000037f0| 73 55 74 69 6c 73 2e 67 | 65 74 54 61 72 67 65 74 |sUtils.g|etTarget|
|00003800| 46 72 6f 6d 46 6f 6c 64 | 65 72 28 61 49 74 65 6d |FromFold|er(aItem|
|00003810| 29 3b 0d 0a 0d 0a 20 20 | 20 20 20 20 20 20 20 20 |);.... | |
|00003820| 52 44 46 43 2e 49 6e 69 | 74 28 74 68 69 73 2e 64 |RDFC.Ini|t(this.d|
|00003830| 62 2c 20 61 50 61 72 65 | 6e 74 29 3b 0d 0a 20 20 |b, aPare|nt);.. |
|00003840| 20 20 20 20 20 20 20 20 | 76 61 72 20 69 6e 64 65 | |var inde|
|00003850| 78 20 3d 20 52 44 46 43 | 2e 49 6e 64 65 78 4f 66 |x = RDFC|.IndexOf|
|00003860| 28 61 49 74 65 6d 29 3b | 0d 0a 20 20 20 20 20 20 |(aItem);|.. |
|00003870| 20 20 20 20 69 66 20 28 | 61 4f 72 69 65 6e 74 61 | if (|aOrienta|
|00003880| 74 69 6f 6e 20 3d 3d 20 | 42 6f 6f 6b 6d 61 72 6b |tion == |Bookmark|
|00003890| 73 55 74 69 6c 73 2e 44 | 52 4f 50 5f 41 46 54 45 |sUtils.D|ROP_AFTE|
|000038a0| 52 29 0d 0a 20 20 20 20 | 20 20 20 20 20 20 20 20 |R).. | |
|000038b0| 2b 2b 69 6e 64 65 78 3b | 0d 0a 20 20 20 20 20 20 |++index;|.. |
|000038c0| 20 20 20 20 72 65 74 75 | 72 6e 20 7b 20 70 61 72 | retu|rn { par|
|000038d0| 65 6e 74 3a 20 61 50 61 | 72 65 6e 74 2c 20 69 6e |ent: aPa|rent, in|
|000038e0| 64 65 78 3a 20 69 6e 64 | 65 78 20 7d 3b 0d 0a 20 |dex: ind|ex };.. |
|000038f0| 20 20 20 20 20 20 20 5d | 5d 3e 3c 2f 62 6f 64 79 | ]|]></body|
|00003900| 3e 0d 0a 20 20 20 20 20 | 20 3c 2f 6d 65 74 68 6f |>.. | </metho|
|00003910| 64 3e 0d 0a 0d 0a 20 20 | 20 20 20 20 23 20 54 68 |d>.... | # Th|
|00003920| 69 73 20 66 75 6e 63 74 | 69 6f 6e 20 73 61 76 65 |is funct|ion save|
|00003930| 73 20 74 68 65 20 63 75 | 72 72 65 6e 74 20 73 65 |s the cu|rrent se|
|00003940| 6c 65 63 74 69 6f 6e 20 | 73 74 61 74 65 20 62 65 |lection |state be|
|00003950| 66 6f 72 65 20 74 68 65 | 20 74 72 65 65 20 69 73 |fore the| tree is|
|00003960| 20 72 65 62 75 69 6c 74 | 0d 0a 20 20 20 20 20 20 | rebuilt|.. |
|00003970| 23 20 66 6f 6c 6c 6f 77 | 69 6e 67 20 61 20 63 6f |# follow|ing a co|
|00003980| 6d 6d 61 6e 64 20 65 78 | 65 63 75 74 69 6f 6e 2e |mmand ex|ecution.|
|00003990| 20 54 68 69 73 20 61 6c | 6c 6f 77 73 20 75 73 20 | This al|lows us |
|000039a0| 74 6f 20 72 65 6d 65 6d | 62 65 72 20 77 68 69 63 |to remem|ber whic|
|000039b0| 68 20 69 74 65 6d 28 73 | 29 0d 0a 20 20 20 20 20 |h item(s|).. |
|000039c0| 20 23 20 77 61 73 2f 77 | 65 72 65 20 73 65 6c 65 | # was/w|ere sele|
|000039d0| 63 74 65 64 20 73 6f 20 | 74 68 61 74 20 74 68 65 |cted so |that the|
|000039e0| 20 75 73 65 72 20 64 6f | 65 73 20 6e 6f 74 20 6e | user do|es not n|
|000039f0| 65 65 64 20 74 6f 20 63 | 6f 6e 73 74 61 6e 74 6c |eed to c|onstantl|
|00003a00| 79 20 72 65 66 6f 63 75 | 73 20 74 68 65 20 0d 0a |y refocu|s the ..|
|00003a10| 20 20 20 20 20 20 23 20 | 74 72 65 65 20 74 6f 20 | # |tree to |
|00003a20| 70 65 72 66 6f 72 6d 20 | 61 20 73 65 71 75 65 6e |perform |a sequen|
|00003a30| 63 65 20 6f 66 20 63 6f | 6d 6d 61 6e 64 73 2e 20 |ce of co|mmands. |
|00003a40| 0d 0a 20 20 20 20 20 20 | 3c 66 69 65 6c 64 20 6e |.. |<field n|
|00003a50| 61 6d 65 3d 22 5f 73 61 | 76 65 64 53 65 6c 65 63 |ame="_sa|vedSelec|
|00003a60| 74 69 6f 6e 22 3e 5b 5d | 3c 2f 66 69 65 6c 64 3e |tion">[]|</field>|
|00003a70| 0d 0a 20 20 20 20 20 20 | 3c 6d 65 74 68 6f 64 20 |.. |<method |
|00003a80| 6e 61 6d 65 3d 22 73 61 | 76 65 53 65 6c 65 63 74 |name="sa|veSelect|
|00003a90| 69 6f 6e 22 3e 0d 0a 20 | 20 20 20 20 20 20 20 3c |ion">.. | <|
|00003aa0| 62 6f 64 79 3e 3c 21 5b | 43 44 41 54 41 5b 0d 0a |body><![|CDATA[..|
|00003ab0| 20 20 20 20 20 20 20 20 | 20 20 76 61 72 20 73 65 | | var se|
|00003ac0| 6c 65 63 74 69 6f 6e 20 | 3d 20 74 68 69 73 2e 74 |lection |= this.t|
|00003ad0| 72 65 65 42 6f 78 4f 62 | 6a 65 63 74 2e 76 69 65 |reeBoxOb|ject.vie|
|00003ae0| 77 2e 73 65 6c 65 63 74 | 69 6f 6e 3b 0d 0a 20 20 |w.select|ion;.. |
|00003af0| 20 20 20 20 20 20 20 20 | 76 61 72 20 72 61 6e 67 | |var rang|
|00003b00| 65 43 6f 75 6e 74 20 3d | 20 73 65 6c 65 63 74 69 |eCount =| selecti|
|00003b10| 6f 6e 2e 67 65 74 52 61 | 6e 67 65 43 6f 75 6e 74 |on.getRa|ngeCount|
|00003b20| 28 29 3b 0d 0a 20 20 20 | 20 20 20 20 20 20 20 76 |();.. | v|
|00003b30| 61 72 20 72 61 6e 67 65 | 73 20 3d 20 5b 5d 3b 0d |ar range|s = [];.|
|00003b40| 0a 20 20 20 20 20 20 20 | 20 20 20 76 61 72 20 6d |. | var m|
|00003b50| 69 6e 20 3d 20 7b 7d 3b | 20 76 61 72 20 6d 61 78 |in = {};| var max|
|00003b60| 20 3d 20 7b 7d 3b 0d 0a | 20 20 20 20 20 20 20 20 | = {};..| |
|00003b70| 20 20 66 6f 72 20 28 76 | 61 72 20 69 20 3d 20 30 | for (v|ar i = 0|
|00003b80| 3b 20 69 20 3c 20 72 61 | 6e 67 65 43 6f 75 6e 74 |; i < ra|ngeCount|
|00003b90| 3b 20 2b 2b 69 29 20 7b | 0d 0a 20 20 20 20 20 20 |; ++i) {|.. |
|00003ba0| 20 20 20 20 20 20 73 65 | 6c 65 63 74 69 6f 6e 2e | se|lection.|
|00003bb0| 67 65 74 52 61 6e 67 65 | 41 74 28 69 2c 20 6d 69 |getRange|At(i, mi|
|00003bc0| 6e 2c 20 6d 61 78 29 3b | 0d 0a 20 20 20 20 20 20 |n, max);|.. |
|00003bd0| 20 20 20 20 20 20 72 61 | 6e 67 65 73 2e 70 75 73 | ra|nges.pus|
|00003be0| 68 28 7b 6d 69 6e 3a 20 | 6d 69 6e 2e 76 61 6c 75 |h({min: |min.valu|
|00003bf0| 65 2c 20 6d 61 78 3a 20 | 6d 61 78 2e 76 61 6c 75 |e, max: |max.valu|
|00003c00| 65 7d 29 3b 0d 0a 20 20 | 20 20 20 20 20 20 20 20 |e});.. | |
|00003c10| 7d 0d 0a 20 20 20 20 20 | 20 20 20 20 20 74 68 69 |}.. | thi|
|00003c20| 73 2e 5f 73 61 76 65 64 | 53 65 6c 65 63 74 69 6f |s._saved|Selectio|
|00003c30| 6e 20 3d 20 72 61 6e 67 | 65 73 3b 0d 0a 20 20 20 |n = rang|es;.. |
|00003c40| 20 20 20 20 20 5d 5d 3e | 3c 2f 62 6f 64 79 3e 0d | ]]>|</body>.|
|00003c50| 0a 20 20 20 20 20 20 3c | 2f 6d 65 74 68 6f 64 3e |. <|/method>|
|00003c60| 0d 0a 20 20 20 20 20 20 | 0d 0a 20 20 20 20 20 20 |.. |.. |
|00003c70| 23 20 54 68 69 73 20 66 | 75 6e 63 74 69 6f 6e 20 |# This f|unction |
|00003c80| 72 65 73 74 6f 72 65 73 | 20 74 68 65 20 73 65 6c |restores| the sel|
|00003c90| 65 63 74 69 6f 6e 20 61 | 70 70 72 6f 70 72 69 61 |ection a|ppropria|
|00003ca0| 74 65 6c 79 20 61 66 74 | 65 72 20 61 20 63 6f 6d |tely aft|er a com|
|00003cb0| 6d 61 6e 64 20 65 78 65 | 63 75 74 65 73 2e 20 0d |mand exe|cutes. .|
|00003cc0| 0a 20 20 20 20 20 20 23 | 20 54 68 69 73 20 69 73 |. #| This is|
|00003cd0| 20 6e 65 63 65 73 73 61 | 72 79 20 62 65 63 61 75 | necessa|ry becau|
|00003ce0| 73 65 20 6d 6f 73 74 20 | 63 6f 6d 6d 61 6e 64 73 |se most |commands|
|00003cf0| 20 74 72 69 67 67 65 72 | 20 61 20 72 65 62 75 69 | trigger| a rebui|
|00003d00| 6c 64 20 6f 66 20 74 68 | 65 20 74 72 65 65 20 77 |ld of th|e tree w|
|00003d10| 68 69 63 68 0d 0a 20 20 | 20 20 20 20 23 20 64 65 |hich.. | # de|
|00003d20| 73 74 72 6f 79 73 20 74 | 68 65 20 73 65 6c 65 63 |stroys t|he selec|
|00003d30| 74 69 6f 6e 2e 20 54 68 | 65 20 72 65 73 74 6f 72 |tion. Th|e restor|
|00003d40| 61 74 69 6f 6e 20 6f 66 | 20 73 65 6c 65 63 74 69 |ation of| selecti|
|00003d50| 6f 6e 20 69 73 20 68 61 | 6e 64 6c 65 64 20 69 6e |on is ha|ndled in|
|00003d60| 20 74 68 72 65 65 20 0d | 0a 20 20 20 20 20 20 23 | three .|. #|
|00003d70| 20 64 69 66 66 65 72 65 | 6e 74 20 77 61 79 73 20 | differe|nt ways |
|00003d80| 64 65 70 65 6e 64 69 6e | 67 20 6f 6e 20 74 68 65 |dependin|g on the|
|00003d90| 20 74 79 70 65 20 6f 66 | 20 63 6f 6d 6d 61 6e 64 | type of| command|
|00003da0| 20 74 68 61 74 20 68 61 | 73 20 62 65 65 6e 20 65 | that ha|s been e|
|00003db0| 78 65 63 75 74 65 64 3a | 0d 0a 20 20 20 20 20 20 |xecuted:|.. |
|00003dc0| 23 20 20 31 29 20 43 6f | 6d 6d 61 6e 64 73 20 74 |# 1) Co|mmands t|
|00003dd0| 68 61 74 20 72 65 6d 6f | 76 65 20 72 6f 77 73 3a |hat remo|ve rows:|
|00003de0| 0d 0a 20 20 20 20 20 20 | 23 20 20 20 20 20 20 20 |.. |# |
|00003df0| 54 68 65 20 72 6f 77 20 | 69 6d 6d 65 64 69 61 74 |The row |immediat|
|00003e00| 65 6c 79 20 61 66 74 65 | 72 20 74 68 65 20 66 69 |ely afte|r the fi|
|00003e10| 72 73 74 20 72 61 6e 67 | 65 20 69 6e 20 74 68 65 |rst rang|e in the|
|00003e20| 20 73 65 6c 65 63 74 69 | 6f 6e 20 69 73 20 73 65 | selecti|on is se|
|00003e30| 6c 65 63 74 65 64 2c 20 | 0d 0a 20 20 20 20 20 20 |lected, |.. |
|00003e40| 23 20 20 20 20 20 20 20 | 69 66 20 74 68 65 72 65 |# |if there|
|00003e50| 20 69 73 20 6e 6f 20 72 | 6f 77 20 69 6d 6d 65 64 | is no r|ow immed|
|00003e60| 69 61 74 65 6c 79 20 61 | 66 74 65 72 20 74 68 65 |iately a|fter the|
|00003e70| 20 66 69 72 73 74 20 72 | 61 6e 67 65 20 74 68 65 | first r|ange the|
|00003e80| 20 69 74 65 6d 20 62 65 | 66 6f 72 65 20 69 74 0d | item be|fore it.|
|00003e90| 0a 20 20 20 20 20 20 23 | 20 20 20 20 20 20 20 69 |. #| i|
|00003ea0| 73 20 73 65 6c 65 63 74 | 65 64 0d 0a 20 20 20 20 |s select|ed.. |
|00003eb0| 20 20 23 20 20 32 29 20 | 43 6f 6d 6d 61 6e 64 73 | # 2) |Commands|
|00003ec0| 20 74 68 61 74 20 69 6e | 73 65 72 74 20 72 6f 77 | that in|sert row|
|00003ed0| 73 3a 0d 0a 20 20 20 20 | 20 20 23 20 20 20 20 20 |s:.. | # |
|00003ee0| 20 20 54 68 65 20 6e 65 | 77 6c 79 20 69 6e 73 65 | The ne|wly inse|
|00003ef0| 72 74 65 64 20 72 6f 77 | 73 20 61 72 65 20 73 65 |rted row|s are se|
|00003f00| 6c 65 63 74 65 64 0d 0a | 20 20 20 20 20 20 23 20 |lected..| # |
|00003f10| 20 33 29 20 43 6f 6d 6d | 61 6e 64 73 20 74 68 61 | 3) Comm|ands tha|
|00003f20| 74 20 64 6f 20 6e 6f 74 | 20 63 68 61 6e 67 65 20 |t do not| change |
|00003f30| 74 68 65 20 72 6f 77 20 | 63 6f 75 6e 74 20 0d 0a |the row |count ..|
|00003f40| 20 20 20 20 20 20 23 20 | 20 20 20 20 20 20 54 68 | # | Th|
|00003f50| 65 20 72 6f 77 28 73 29 | 20 74 68 61 74 20 77 61 |e row(s)| that wa|
|00003f60| 73 2f 77 65 72 65 20 6f | 70 65 72 61 74 65 64 20 |s/were o|perated |
|00003f70| 6f 6e 20 72 65 6d 61 69 | 6e 20 73 65 6c 65 63 74 |on remai|n select|
|00003f80| 65 64 2e 0d 0a 20 20 20 | 20 20 20 23 20 0d 0a 20 |ed... | # .. |
|00003f90| 20 20 20 20 20 23 20 54 | 68 65 20 63 61 6c 6c 73 | # T|he calls|
|00003fa0| 20 74 6f 20 73 61 76 65 | 2f 72 65 73 74 6f 72 65 | to save|/restore|
|00003fb0| 20 61 72 65 20 70 6c 61 | 63 65 64 20 69 6e 20 74 | are pla|ced in t|
|00003fc0| 68 65 20 64 6f 43 6f 6d | 6d 61 6e 64 20 6d 65 74 |he doCom|mand met|
|00003fd0| 68 6f 64 20 61 6e 64 20 | 74 68 75 73 20 61 6c 6c |hod and |thus all|
|00003fe0| 0d 0a 20 20 20 20 20 20 | 23 20 63 6f 6d 6d 61 6e |.. |# comman|
|00003ff0| 64 73 20 6d 75 73 74 20 | 70 61 73 73 20 74 68 72 |ds must |pass thr|
|00004000| 6f 75 67 68 20 74 68 69 | 73 20 67 61 74 65 2e 20 |ough thi|s gate. |
|00004010| 54 68 65 20 72 65 73 75 | 6c 74 20 69 73 20 74 68 |The resu|lt is th|
|00004020| 61 74 20 74 68 69 73 20 | 6d 65 74 68 6f 64 20 62 |at this |method b|
|00004030| 65 63 6f 6d 65 73 0d 0a | 20 20 20 20 20 20 23 20 |ecomes..| # |
|00004040| 74 68 65 20 50 4f 4c 49 | 43 59 20 43 45 4e 54 45 |the POLI|CY CENTE|
|00004050| 52 20 46 4f 52 20 50 4f | 53 54 2d 56 49 45 57 2f |R FOR PO|ST-VIEW/|
|00004060| 45 44 49 54 20 53 45 4c | 45 43 54 49 4f 4e 20 43 |EDIT SEL|ECTION C|
|00004070| 48 41 4e 47 45 53 2e 0d | 0a 20 20 20 20 20 20 3c |HANGES..|. <|
|00004080| 6d 65 74 68 6f 64 20 6e | 61 6d 65 3d 22 72 65 73 |method n|ame="res|
|00004090| 74 6f 72 65 53 65 6c 65 | 63 74 69 6f 6e 22 3e 0d |toreSele|ction">.|
|000040a0| 0a 20 20 20 20 20 20 20 | 20 3c 70 61 72 61 6d 65 |. | <parame|
|000040b0| 74 65 72 20 6e 61 6d 65 | 3d 22 61 43 6f 6d 6d 61 |ter name|="aComma|
|000040c0| 6e 64 22 2f 3e 0d 0a 20 | 20 20 20 20 20 20 20 3c |nd"/>.. | <|
|000040d0| 62 6f 64 79 3e 3c 21 5b | 43 44 41 54 41 5b 20 0d |body><![|CDATA[ .|
|000040e0| 0a 20 20 20 20 20 20 20 | 20 20 20 76 61 72 20 6f |. | var o|
|000040f0| 6c 64 52 61 6e 67 65 73 | 20 3d 20 74 68 69 73 2e |ldRanges| = this.|
|00004100| 5f 73 61 76 65 64 53 65 | 6c 65 63 74 69 6f 6e 3b |_savedSe|lection;|
|00004110| 0d 0a 20 20 20 20 20 20 | 20 20 20 20 76 61 72 20 |.. | var |
|00004120| 6e 65 77 52 61 6e 67 65 | 73 20 3d 20 5b 5d 3b 0d |newRange|s = [];.|
|00004130| 0a 0d 0a 20 20 20 20 20 | 20 20 20 20 20 73 77 69 |... | swi|
|00004140| 74 63 68 28 61 43 6f 6d | 6d 61 6e 64 29 20 7b 0d |tch(aCom|mand) {.|
|00004150| 0a 20 20 20 20 20 20 20 | 20 20 20 2f 2f 20 5b 43 |. | // [C|
|00004160| 61 74 65 67 6f 72 79 20 | 31 5d 20 2d 20 43 6f 6d |ategory |1] - Com|
|00004170| 6d 61 6e 64 73 20 74 68 | 61 74 20 72 65 6d 6f 76 |mands th|at remov|
|00004180| 65 20 72 6f 77 73 0d 0a | 20 20 20 20 20 20 20 20 |e rows..| |
|00004190| 20 20 63 61 73 65 20 22 | 63 6d 64 5f 63 75 74 22 | case "|cmd_cut"|
|000041a0| 3a 0d 0a 20 20 20 20 20 | 20 20 20 20 20 63 61 73 |:.. | cas|
|000041b0| 65 20 22 63 6d 64 5f 64 | 65 6c 65 74 65 22 3a 0d |e "cmd_d|elete":.|
|000041c0| 0a 20 20 20 20 20 20 20 | 20 20 20 20 20 2f 2f 20 |. | // |
|000041d0| 53 69 6e 63 65 20 72 6f | 77 73 20 68 61 76 65 20 |Since ro|ws have |
|000041e0| 62 65 65 6e 20 72 65 6d | 6f 76 65 64 2c 20 74 68 |been rem|oved, th|
|000041f0| 65 20 72 6f 77 20 69 6d | 6d 65 64 69 61 74 65 6c |e row im|mediatel|
|00004200| 79 20 61 66 74 65 72 20 | 74 68 65 20 66 69 72 73 |y after |the firs|
|00004210| 74 20 72 61 6e 67 65 20 | 0d 0a 20 20 20 20 20 20 |t range |.. |
|00004220| 20 20 20 20 20 20 2f 2f | 20 69 6e 20 74 68 65 20 | //| in the |
|00004230| 6f 72 69 67 69 6e 61 6c | 20 73 65 6c 65 63 74 69 |original| selecti|
|00004240| 6f 6e 20 6e 6f 77 20 68 | 61 73 20 74 68 65 20 69 |on now h|as the i|
|00004250| 6e 64 65 78 20 6f 66 20 | 74 68 65 20 66 69 72 73 |ndex of |the firs|
|00004260| 74 20 69 74 65 6d 20 69 | 6e 20 74 68 65 20 66 69 |t item i|n the fi|
|00004270| 72 73 74 0d 0a 20 20 20 | 20 20 20 20 20 20 20 20 |rst.. | |
|00004280| 20 2f 2f 20 72 61 6e 67 | 65 2e 20 0d 0a 20 20 20 | // rang|e. .. |
|00004290| 20 20 20 20 20 20 20 20 | 20 76 61 72 20 6e 65 78 | | var nex|
|000042a0| 74 52 6f 77 20 3d 20 6f | 6c 64 52 61 6e 67 65 73 |tRow = o|ldRanges|
|000042b0| 5b 30 5d 2e 6d 69 6e 3b | 0d 0a 20 20 20 20 20 20 |[0].min;|.. |
|000042c0| 20 20 20 20 20 20 6e 65 | 77 52 61 6e 67 65 73 2e | ne|wRanges.|
|000042d0| 70 75 73 68 28 7b 6d 69 | 6e 3a 20 6e 65 78 74 52 |push({mi|n: nextR|
|000042e0| 6f 77 2c 20 6d 61 78 3a | 20 6e 65 78 74 52 6f 77 |ow, max:| nextRow|
|000042f0| 7d 29 3b 0d 0a 20 20 20 | 20 20 20 20 20 20 20 20 |});.. | |
|00004300| 20 62 72 65 61 6b 3b 0d | 0a 20 20 20 20 20 20 20 | break;.|. |
|00004310| 20 20 20 2f 2f 20 5b 43 | 61 74 65 67 6f 72 79 20 | // [C|ategory |
|00004320| 32 5d 20 2d 20 43 6f 6d | 6d 61 6e 64 73 20 74 68 |2] - Com|mands th|
|00004330| 61 74 20 69 6e 73 65 72 | 74 20 72 6f 77 73 0d 0a |at inser|t rows..|
|00004340| 20 20 20 20 20 20 20 20 | 20 20 63 61 73 65 20 22 | | case "|
|00004350| 63 6d 64 5f 70 61 73 74 | 65 22 3a 0d 0a 20 20 20 |cmd_past|e":.. |
|00004360| 20 20 20 20 20 20 20 63 | 61 73 65 20 22 63 6d 64 | c|ase "cmd|
|00004370| 5f 62 6d 5f 69 6d 70 6f | 72 74 22 3a 0d 0a 20 20 |_bm_impo|rt":.. |
|00004380| 20 20 20 20 20 20 20 20 | 63 61 73 65 20 22 63 6d | |case "cm|
|00004390| 64 5f 62 6d 5f 6d 6f 76 | 65 62 6f 6f 6b 6d 61 72 |d_bm_mov|ebookmar|
|000043a0| 6b 22 3a 0d 0a 20 20 20 | 20 20 20 20 20 20 20 63 |k":.. | c|
|000043b0| 61 73 65 20 22 63 6d 64 | 5f 62 6d 5f 6e 65 77 62 |ase "cmd|_bm_newb|
|000043c0| 6f 6f 6b 6d 61 72 6b 22 | 3a 0d 0a 20 20 20 20 20 |ookmark"|:.. |
|000043d0| 20 20 20 20 20 63 61 73 | 65 20 22 63 6d 64 5f 62 | cas|e "cmd_b|
|000043e0| 6d 5f 6e 65 77 66 6f 6c | 64 65 72 22 3a 0d 0a 20 |m_newfol|der":.. |
|000043f0| 20 20 20 20 20 20 20 20 | 20 63 61 73 65 20 22 63 | | case "c|
|00004400| 6d 64 5f 62 6d 5f 6e 65 | 77 73 65 70 61 72 61 74 |md_bm_ne|wseparat|
|00004410| 6f 72 22 3a 0d 0a 20 20 | 20 20 20 20 20 20 20 20 |or":.. | |
|00004420| 63 61 73 65 20 22 63 6d | 64 5f 75 6e 64 6f 22 3a |case "cm|d_undo":|
|00004430| 20 2f 2f 58 58 58 70 63 | 68 3a 20 64 6f 65 73 6e | //XXXpc|h: doesn|
|00004440| 27 74 20 77 6f 72 6b 20 | 66 6f 72 20 69 6e 73 65 |'t work |for inse|
|00004450| 72 74 0d 0a 20 20 20 20 | 20 20 20 20 20 20 63 61 |rt.. | ca|
|00004460| 73 65 20 22 63 6d 64 5f | 72 65 64 6f 22 3a 20 2f |se "cmd_|redo": /|
|00004470| 2f 58 58 58 70 63 68 3a | 20 64 6f 65 73 6e 27 74 |/XXXpch:| doesn't|
|00004480| 20 77 6f 72 6b 20 66 6f | 72 20 72 65 6d 6f 76 65 | work fo|r remove|
|00004490| 0d 0a 20 20 20 20 20 20 | 20 20 20 20 20 20 2f 2f |.. | //|
|000044a0| 20 41 6c 6c 20 69 74 65 | 6d 73 20 69 6e 73 65 72 | All ite|ms inser|
|000044b0| 74 65 64 20 77 69 6c 6c | 20 62 65 20 73 65 6c 65 |ted will| be sele|
|000044c0| 63 74 65 64 2e 20 54 68 | 65 20 69 6d 70 6c 65 6d |cted. Th|e implem|
|000044d0| 65 6e 74 61 74 69 6f 6e | 20 6f 66 20 74 68 69 73 |entation| of this|
|000044e0| 20 6d 6f 64 65 6c 0d 0a | 20 20 20 20 20 20 20 20 | model..| |
|000044f0| 20 20 20 20 2f 2f 20 69 | 73 20 6c 65 66 74 20 74 | // i|s left t|
|00004500| 6f 20 7c 70 72 65 55 70 | 64 61 74 65 54 72 65 65 |o |preUp|dateTree|
|00004510| 53 65 6c 65 63 74 69 6f | 6e 7c 2c 20 63 61 6c 6c |Selectio|n|, call|
|00004520| 65 64 20 77 68 65 6e 20 | 61 6e 20 69 6e 73 65 72 |ed when |an inser|
|00004530| 74 20 74 72 61 6e 73 61 | 63 74 69 6f 6e 20 69 73 |t transa|ction is|
|00004540| 0d 0a 20 20 20 20 20 20 | 20 20 20 20 20 20 2f 2f |.. | //|
|00004550| 20 65 78 65 63 75 74 65 | 64 2c 20 61 6e 64 20 7c | execute|d, and ||
|00004560| 75 70 64 61 74 65 54 72 | 65 65 53 65 6c 65 63 74 |updateTr|eeSelect|
|00004570| 69 6f 6e 7c 20 63 61 6c | 6c 65 64 20 68 65 72 65 |ion| cal|led here|
|00004580| 2e 20 0d 0a 20 20 20 20 | 20 20 20 20 20 20 20 20 |. .. | |
|00004590| 74 68 69 73 2e 75 70 64 | 61 74 65 54 72 65 65 53 |this.upd|ateTreeS|
|000045a0| 65 6c 65 63 74 69 6f 6e | 28 29 3b 0d 0a 20 20 20 |election|();.. |
|000045b0| 20 20 20 20 20 20 20 20 | 20 62 72 65 61 6b 3b 0d | | break;.|
|000045c0| 0a 20 20 20 20 20 20 20 | 20 20 20 2f 2f 20 5b 43 |. | // [C|
|000045d0| 61 74 65 67 6f 72 79 20 | 33 5d 20 2d 20 43 6f 6d |ategory |3] - Com|
|000045e0| 6d 61 6e 64 73 20 74 68 | 61 74 20 64 6f 20 6e 6f |mands th|at do no|
|000045f0| 74 20 61 6c 74 65 72 20 | 74 68 65 20 72 6f 77 20 |t alter |the row |
|00004600| 63 6f 75 6e 74 0d 0a 20 | 20 20 20 20 20 20 20 20 |count.. | |
|00004610| 20 63 61 73 65 20 22 63 | 6d 64 5f 63 6f 70 79 22 | case "c|md_copy"|
|00004620| 3a 0d 0a 20 20 20 20 20 | 20 20 20 20 20 63 61 73 |:.. | cas|
|00004630| 65 20 22 63 6d 64 5f 62 | 6d 5f 70 72 6f 70 65 72 |e "cmd_b|m_proper|
|00004640| 74 69 65 73 22 3a 0d 0a | 20 20 20 20 20 20 20 20 |ties":..| |
|00004650| 20 20 63 61 73 65 20 22 | 63 6d 64 5f 62 6d 5f 72 | case "|cmd_bm_r|
|00004660| 65 6e 61 6d 65 22 3a 0d | 0a 20 20 20 20 20 20 20 |ename":.|. |
|00004670| 20 20 20 63 61 73 65 20 | 22 63 6d 64 5f 62 6d 5f | case |"cmd_bm_|
|00004680| 73 65 74 70 65 72 73 6f | 6e 61 6c 74 6f 6f 6c 62 |setperso|naltoolb|
|00004690| 61 72 66 6f 6c 64 65 72 | 22 3a 0d 0a 20 20 20 20 |arfolder|":.. |
|000046a0| 20 20 20 20 20 20 63 61 | 73 65 20 22 63 6d 64 5f | ca|se "cmd_|
|000046b0| 62 6d 5f 65 78 70 6f 72 | 74 22 3a 0d 0a 20 20 20 |bm_expor|t":.. |
|000046c0| 20 20 20 20 20 20 20 64 | 65 66 61 75 6c 74 3a 0d | d|efault:.|
|000046d0| 0a 20 20 20 20 20 20 20 | 20 20 20 20 20 2f 2f 20 |. | // |
|000046e0| 54 68 65 20 73 65 6c 65 | 63 74 69 6f 6e 20 69 73 |The sele|ction is|
|000046f0| 20 75 6e 63 68 61 6e 67 | 65 64 2e 0d 0a 20 20 20 | unchang|ed... |
|00004700| 20 20 20 20 20 20 20 20 | 20 72 65 74 75 72 6e 3b | | return;|
|00004710| 0d 0a 20 20 20 20 20 20 | 20 20 20 20 7d 0d 0a 20 |.. | }.. |
|00004720| 20 20 20 20 20 20 20 20 | 20 0d 0a 20 20 20 20 20 | | .. |
|00004730| 20 20 20 20 20 76 61 72 | 20 6e 65 77 53 65 6c 65 | var| newSele|
|00004740| 63 74 69 6f 6e 20 3d 20 | 74 68 69 73 2e 74 72 65 |ction = |this.tre|
|00004750| 65 42 6f 78 4f 62 6a 65 | 63 74 2e 76 69 65 77 2e |eBoxObje|ct.view.|
|00004760| 73 65 6c 65 63 74 69 6f | 6e 3b 0d 0a 20 20 20 20 |selectio|n;.. |
|00004770| 20 20 20 20 20 20 66 6f | 72 20 28 69 20 3d 20 30 | fo|r (i = 0|
|00004780| 3b 20 69 20 3c 20 6e 65 | 77 52 61 6e 67 65 73 2e |; i < ne|wRanges.|
|00004790| 6c 65 6e 67 74 68 3b 20 | 2b 2b 69 29 0d 0a 20 20 |length; |++i).. |
|000047a0| 20 20 20 20 20 20 20 20 | 20 20 6e 65 77 53 65 6c | | newSel|
|000047b0| 65 63 74 69 6f 6e 2e 72 | 61 6e 67 65 64 53 65 6c |ection.r|angedSel|
|000047c0| 65 63 74 28 6e 65 77 52 | 61 6e 67 65 73 5b 69 5d |ect(newR|anges[i]|
|000047d0| 2e 6d 69 6e 2c 20 6e 65 | 77 52 61 6e 67 65 73 5b |.min, ne|wRanges[|
|000047e0| 69 5d 2e 6d 61 78 2c 20 | 74 72 75 65 29 3b 0d 0a |i].max, |true);..|
|000047f0| 20 20 20 20 20 20 20 20 | 5d 5d 3e 3c 2f 62 6f 64 | |]]></bod|
|00004800| 79 3e 0d 0a 20 20 20 20 | 20 20 3c 2f 6d 65 74 68 |y>.. | </meth|
|00004810| 6f 64 3e 0d 0a 0d 0a 20 | 20 20 20 20 20 3c 66 69 |od>.... | <fi|
|00004820| 65 6c 64 20 6e 61 6d 65 | 3d 22 5f 69 74 65 6d 54 |eld name|="_itemT|
|00004830| 6f 42 65 54 6f 67 67 6c | 65 64 22 3e 20 20 5b 5d |oBeToggl|ed"> []|
|00004840| 3c 2f 66 69 65 6c 64 3e | 0d 0a 20 20 20 20 20 20 |</field>|.. |
|00004850| 2f 2f 20 6b 65 65 70 20 | 74 72 61 63 6b 20 6f 66 |// keep |track of|
|00004860| 20 74 68 65 20 69 74 65 | 6d 73 20 74 68 61 74 20 | the ite|ms that |
|00004870| 77 65 20 77 69 6c 6c 20 | 73 65 6c 65 63 74 0d 0a |we will |select..|
|00004880| 20 20 20 20 20 20 2f 2f | 20 62 65 63 61 75 73 65 | //| because|
|00004890| 20 77 65 20 63 61 6e 20 | 6e 6f 74 20 73 65 6c 65 | we can |not sele|
|000048a0| 63 74 20 72 6f 77 73 20 | 64 75 72 69 6e 67 20 61 |ct rows |during a|
|000048b0| 20 62 61 74 63 68 2e 0d | 0a 20 20 20 20 20 20 3c | batch..|. <|
|000048c0| 6d 65 74 68 6f 64 20 6e | 61 6d 65 3d 22 70 72 65 |method n|ame="pre|
|000048d0| 55 70 64 61 74 65 54 72 | 65 65 53 65 6c 65 63 74 |UpdateTr|eeSelect|
|000048e0| 69 6f 6e 22 3e 0d 0a 20 | 20 20 20 20 20 20 20 3c |ion">.. | <|
|000048f0| 70 61 72 61 6d 65 74 65 | 72 20 6e 61 6d 65 3d 22 |paramete|r name="|
|00004900| 61 54 78 6e 22 2f 3e 0d | 0a 20 20 20 20 20 20 20 |aTxn"/>.|. |
|00004910| 20 3c 70 61 72 61 6d 65 | 74 65 72 20 6e 61 6d 65 | <parame|ter name|
|00004920| 3d 22 61 44 6f 22 2f 3e | 0d 0a 20 20 20 20 20 20 |="aDo"/>|.. |
|00004930| 20 20 3c 62 6f 64 79 3e | 3c 21 5b 43 44 41 54 41 | <body>|<![CDATA|
|00004940| 5b 0d 0a 20 20 20 20 20 | 20 20 20 20 20 61 54 78 |[.. | aTx|
|00004950| 6e 20 3d 20 61 54 78 6e | 2e 77 72 61 70 70 65 64 |n = aTxn|.wrapped|
|00004960| 4a 53 4f 62 6a 65 63 74 | 3b 0d 0a 20 20 20 20 20 |JSObject|;.. |
|00004970| 20 20 20 20 20 76 61 72 | 20 74 79 70 65 20 3d 20 | var| type = |
|00004980| 61 54 78 6e 2e 74 79 70 | 65 3b 0d 0a 20 20 20 20 |aTxn.typ|e;.. |
|00004990| 20 20 20 20 20 20 2f 2f | 20 53 6b 69 70 20 74 72 | //| Skip tr|
|000049a0| 61 6e 73 61 63 74 69 6f | 6e 73 20 74 68 61 74 20 |ansactio|ns that |
|000049b0| 61 67 67 72 65 67 61 74 | 65 73 20 6e 65 73 74 65 |aggregat|es neste|
|000049c0| 64 20 22 69 6e 73 65 72 | 74 22 20 6f 72 20 22 72 |d "inser|t" or "r|
|000049d0| 65 6d 6f 76 65 22 20 74 | 72 61 6e 73 61 63 74 69 |emove" t|ransacti|
|000049e0| 6f 6e 73 2e 0d 0a 20 20 | 20 20 20 20 20 20 20 20 |ons... | |
|000049f0| 69 66 20 28 28 74 79 70 | 65 20 3d 3d 20 22 69 6e |if ((typ|e == "in|
|00004a00| 73 65 72 74 22 29 20 26 | 26 20 61 44 6f 20 7c 7c |sert") &|& aDo |||
|00004a10| 20 28 74 79 70 65 20 3d | 3d 20 22 72 65 6d 6f 76 | (type =|= "remov|
|00004a20| 65 22 29 20 26 26 20 21 | 61 44 6f 29 0d 0a 20 20 |e") && !|aDo).. |
|00004a30| 20 20 20 20 20 20 20 20 | 20 20 74 68 69 73 2e 5f | | this._|
|00004a40| 69 74 65 6d 54 6f 42 65 | 54 6f 67 67 6c 65 64 20 |itemToBe|Toggled |
|00004a50| 3d 20 61 54 78 6e 2e 69 | 74 65 6d 3b 0d 0a 20 20 |= aTxn.i|tem;.. |
|00004a60| 20 20 20 20 20 20 5d 5d | 3e 3c 2f 62 6f 64 79 3e | ]]|></body>|
|00004a70| 0d 0a 20 20 20 20 20 20 | 3c 2f 6d 65 74 68 6f 64 |.. |</method|
|00004a80| 3e 0d 0a 0d 0a 20 20 20 | 20 20 20 3c 6d 65 74 68 |>.... | <meth|
|00004a90| 6f 64 20 6e 61 6d 65 3d | 22 75 70 64 61 74 65 54 |od name=|"updateT|
|00004aa0| 72 65 65 53 65 6c 65 63 | 74 69 6f 6e 22 3e 0d 0a |reeSelec|tion">..|
|00004ab0| 20 20 20 20 20 20 20 20 | 3c 62 6f 64 79 3e 3c 21 | |<body><!|
|00004ac0| 5b 43 44 41 54 41 5b 0d | 0a 20 20 20 20 20 20 20 |[CDATA[.|. |
|00004ad0| 20 20 20 74 68 69 73 2e | 74 72 65 65 42 6f 78 4f | this.|treeBoxO|
|00004ae0| 62 6a 65 63 74 2e 73 65 | 6c 65 63 74 69 6f 6e 2e |bject.se|lection.|
|00004af0| 63 6c 65 61 72 53 65 6c | 65 63 74 69 6f 6e 28 29 |clearSel|ection()|
|00004b00| 3b 0d 0a 20 20 20 20 20 | 20 20 20 20 20 66 6f 72 |;.. | for|
|00004b10| 20 28 76 61 72 20 69 3d | 30 3b 20 69 3c 74 68 69 | (var i=|0; i<thi|
|00004b20| 73 2e 5f 69 74 65 6d 54 | 6f 42 65 54 6f 67 67 6c |s._itemT|oBeToggl|
|00004b30| 65 64 2e 6c 65 6e 67 74 | 68 3b 20 2b 2b 69 29 20 |ed.lengt|h; ++i) |
|00004b40| 7b 0d 0a 20 20 20 20 20 | 20 20 20 20 20 20 20 69 |{.. | i|
|00004b50| 6e 64 65 78 20 3d 20 74 | 68 69 73 2e 74 72 65 65 |ndex = t|his.tree|
|00004b60| 42 75 69 6c 64 65 72 2e | 67 65 74 49 6e 64 65 78 |Builder.|getIndex|
|00004b70| 4f 66 52 65 73 6f 75 72 | 63 65 28 74 68 69 73 2e |OfResour|ce(this.|
|00004b80| 5f 69 74 65 6d 54 6f 42 | 65 54 6f 67 67 6c 65 64 |_itemToB|eToggled|
|00004b90| 5b 69 5d 29 3b 0d 0a 20 | 20 20 20 20 20 20 20 20 |[i]);.. | |
|00004ba0| 20 20 20 69 66 20 28 69 | 6e 64 65 78 20 21 3d 20 | if (i|ndex != |
|00004bb0| 2d 31 20 26 26 20 21 74 | 68 69 73 2e 74 72 65 65 |-1 && !t|his.tree|
|00004bc0| 42 6f 78 4f 62 6a 65 63 | 74 2e 73 65 6c 65 63 74 |BoxObjec|t.select|
|00004bd0| 69 6f 6e 2e 69 73 53 65 | 6c 65 63 74 65 64 28 69 |ion.isSe|lected(i|
|00004be0| 6e 64 65 78 29 29 0d 0a | 20 20 20 20 20 20 20 20 |ndex))..| |
|00004bf0| 20 20 20 20 20 20 74 68 | 69 73 2e 74 72 65 65 42 | th|is.treeB|
|00004c00| 6f 78 4f 62 6a 65 63 74 | 2e 73 65 6c 65 63 74 69 |oxObject|.selecti|
|00004c10| 6f 6e 2e 74 6f 67 67 6c | 65 53 65 6c 65 63 74 28 |on.toggl|eSelect(|
|00004c20| 69 6e 64 65 78 29 3b 0d | 0a 20 20 20 20 20 20 20 |index);.|. |
|00004c30| 20 20 20 7d 0d 0a 20 20 | 20 20 20 20 20 20 5d 5d | }.. | ]]|
|00004c40| 3e 3c 2f 62 6f 64 79 3e | 0d 0a 20 20 20 20 20 20 |></body>|.. |
|00004c50| 3c 2f 6d 65 74 68 6f 64 | 3e 0d 0a 0d 0a 20 20 20 |</method|>.... |
|00004c60| 20 20 20 3c 6d 65 74 68 | 6f 64 20 6e 61 6d 65 3d | <meth|od name=|
|00004c70| 22 63 72 65 61 74 65 54 | 72 65 65 43 6f 6e 74 65 |"createT|reeConte|
|00004c80| 78 74 4d 65 6e 75 22 3e | 0d 0a 20 20 20 20 20 20 |xtMenu">|.. |
|00004c90| 20 20 3c 70 61 72 61 6d | 65 74 65 72 20 6e 61 6d | <param|eter nam|
|00004ca0| 65 3d 22 61 45 76 65 6e | 74 22 2f 3e 0d 0a 20 20 |e="aEven|t"/>.. |
|00004cb0| 20 20 20 20 20 20 3c 62 | 6f 64 79 3e 3c 21 5b 43 | <b|ody><![C|
|00004cc0| 44 41 54 41 5b 0d 0a 20 | 20 20 20 20 20 20 20 20 |DATA[.. | |
|00004cd0| 20 76 61 72 20 73 65 6c | 65 63 74 69 6f 6e 20 3d | var sel|ection =|
|00004ce0| 20 74 68 69 73 2e 5f 73 | 65 6c 65 63 74 69 6f 6e | this._s|election|
|00004cf0| 3b 0d 0a 20 20 20 20 20 | 20 20 20 20 20 76 61 72 |;.. | var|
|00004d00| 20 74 61 72 67 65 74 20 | 20 20 20 3d 20 74 68 69 | target | = thi|
|00004d10| 73 2e 5f 74 61 72 67 65 | 74 3b 0d 0a 20 20 20 20 |s._targe|t;.. |
|00004d20| 20 20 20 20 20 20 42 6f | 6f 6b 6d 61 72 6b 73 43 | Bo|okmarksC|
|00004d30| 6f 6d 6d 61 6e 64 2e 63 | 72 65 61 74 65 43 6f 6e |ommand.c|reateCon|
|00004d40| 74 65 78 74 4d 65 6e 75 | 28 61 45 76 65 6e 74 2c |textMenu|(aEvent,|
|00004d50| 20 73 65 6c 65 63 74 69 | 6f 6e 29 3b 0d 0a 20 20 | selecti|on);.. |
|00004d60| 20 20 20 20 20 20 20 20 | 74 68 69 73 2e 6f 6e 43 | |this.onC|
|00004d70| 6f 6d 6d 61 6e 64 55 70 | 64 61 74 65 28 29 3b 0d |ommandUp|date();.|
|00004d80| 0a 20 20 20 20 20 20 20 | 20 5d 5d 3e 3c 2f 62 6f |. | ]]></bo|
|00004d90| 64 79 3e 0d 0a 20 20 20 | 20 20 20 3c 2f 6d 65 74 |dy>.. | </met|
|00004da0| 68 6f 64 3e 0d 0a 0d 0a | 20 20 20 20 20 20 3c 6d |hod>....| <m|
|00004db0| 65 74 68 6f 64 20 6e 61 | 6d 65 3d 22 6f 70 65 6e |ethod na|me="open|
|00004dc0| 49 74 65 6d 43 6c 69 63 | 6b 22 3e 0d 0a 20 20 20 |ItemClic|k">.. |
|00004dd0| 20 20 20 20 20 3c 70 61 | 72 61 6d 65 74 65 72 20 | <pa|rameter |
|00004de0| 6e 61 6d 65 3d 22 61 45 | 76 65 6e 74 22 2f 3e 0d |name="aE|vent"/>.|
|00004df0| 0a 20 20 20 20 20 20 20 | 20 3c 70 61 72 61 6d 65 |. | <parame|
|00004e00| 74 65 72 20 6e 61 6d 65 | 3d 22 61 43 6c 69 63 6b |ter name|="aClick|
|00004e10| 43 6f 75 6e 74 22 2f 3e | 0d 0a 20 20 20 20 20 20 |Count"/>|.. |
|00004e20| 20 20 3c 62 6f 64 79 3e | 3c 21 5b 43 44 41 54 41 | <body>|<![CDATA|
|00004e30| 5b 0d 0a 20 20 20 20 20 | 20 20 20 20 20 69 66 20 |[.. | if |
|00004e40| 28 61 45 76 65 6e 74 2e | 62 75 74 74 6f 6e 20 3d |(aEvent.|button =|
|00004e50| 3d 20 32 20 7c 7c 20 61 | 45 76 65 6e 74 2e 6f 72 |= 2 || a|Event.or|
|00004e60| 69 67 69 6e 61 6c 54 61 | 72 67 65 74 2e 6c 6f 63 |iginalTa|rget.loc|
|00004e70| 61 6c 4e 61 6d 65 20 21 | 3d 20 22 74 72 65 65 63 |alName !|= "treec|
|00004e80| 68 69 6c 64 72 65 6e 22 | 29 0d 0a 20 20 20 20 20 |hildren"|).. |
|00004e90| 20 20 20 20 20 20 20 72 | 65 74 75 72 6e 3b 0d 0a | r|eturn;..|
|00004ea0| 20 20 20 20 20 20 20 20 | 20 20 69 66 20 28 61 43 | | if (aC|
|00004eb0| 6c 69 63 6b 43 6f 75 6e | 74 20 21 3d 20 74 68 69 |lickCoun|t != thi|
|00004ec0| 73 2e 63 6c 69 63 6b 43 | 6f 75 6e 74 20 26 26 20 |s.clickC|ount && |
|00004ed0| 61 45 76 65 6e 74 2e 62 | 75 74 74 6f 6e 20 21 3d |aEvent.b|utton !=|
|00004ee0| 20 31 29 0d 0a 20 20 20 | 20 20 20 20 20 20 20 20 | 1).. | |
|00004ef0| 20 72 65 74 75 72 6e 3b | 0d 0a 0d 0a 20 20 20 20 | return;|.... |
|00004f00| 20 20 20 20 20 20 76 61 | 72 20 72 6f 77 20 3d 20 | va|r row = |
|00004f10| 7b 7d 3b 0d 0a 20 20 20 | 20 20 20 20 20 20 20 76 |{};.. | v|
|00004f20| 61 72 20 63 6f 6c 20 3d | 20 7b 7d 3b 0d 0a 20 20 |ar col =| {};.. |
|00004f30| 20 20 20 20 20 20 20 20 | 76 61 72 20 6f 62 6a 20 | |var obj |
|00004f40| 3d 20 7b 7d 3b 0d 0a 20 | 20 20 20 20 20 20 20 20 |= {};.. | |
|00004f50| 20 74 68 69 73 2e 74 72 | 65 65 42 6f 78 4f 62 6a | this.tr|eeBoxObj|
|00004f60| 65 63 74 2e 67 65 74 43 | 65 6c 6c 41 74 28 61 45 |ect.getC|ellAt(aE|
|00004f70| 76 65 6e 74 2e 63 6c 69 | 65 6e 74 58 2c 20 61 45 |vent.cli|entX, aE|
|00004f80| 76 65 6e 74 2e 63 6c 69 | 65 6e 74 59 2c 20 72 6f |vent.cli|entY, ro|
|00004f90| 77 2c 20 63 6f 6c 2c 20 | 6f 62 6a 29 3b 0d 0a 20 |w, col, |obj);.. |
|00004fa0| 20 20 20 20 20 20 20 20 | 20 72 6f 77 20 3d 20 72 | | row = r|
|00004fb0| 6f 77 2e 76 61 6c 75 65 | 3b 0d 0a 0d 0a 20 20 20 |ow.value|;.... |
|00004fc0| 20 20 20 20 20 20 20 69 | 66 20 28 72 6f 77 20 3d | i|f (row =|
|00004fd0| 3d 20 2d 31 20 7c 7c 20 | 6f 62 6a 2e 76 61 6c 75 |= -1 || |obj.valu|
|00004fe0| 65 20 3d 3d 20 22 74 77 | 69 73 74 79 22 29 0d 0a |e == "tw|isty")..|
|00004ff0| 20 20 20 20 20 20 20 20 | 20 20 20 20 72 65 74 75 | | retu|
|00005000| 72 6e 3b 0d 0a 20 20 20 | 20 20 20 20 20 20 20 76 |rn;.. | v|
|00005010| 61 72 20 6d 6f 64 69 66 | 4b 65 79 20 3d 20 61 45 |ar modif|Key = aE|
|00005020| 76 65 6e 74 2e 73 68 69 | 66 74 4b 65 79 20 7c 7c |vent.shi|ftKey |||
|00005030| 20 61 45 76 65 6e 74 2e | 63 74 72 6c 4b 65 79 20 | aEvent.|ctrlKey |
|00005040| 7c 7c 20 61 45 76 65 6e | 74 2e 61 6c 74 4b 65 79 ||| aEven|t.altKey|
|00005050| 20 7c 7c 20 0d 0a 20 20 | 20 20 20 20 20 20 20 20 | || .. | |
|00005060| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 20 20 61 | | a|
|00005070| 45 76 65 6e 74 2e 6d 65 | 74 61 4b 65 79 20 20 7c |Event.me|taKey ||
|00005080| 7c 20 61 45 76 65 6e 74 | 2e 62 75 74 74 6f 6e 20 || aEvent|.button |
|00005090| 3d 3d 20 31 3b 0d 0a 20 | 20 20 20 20 20 20 20 20 |== 1;.. | |
|000050a0| 20 69 66 20 28 74 68 69 | 73 2e 63 6c 69 63 6b 43 | if (thi|s.clickC|
|000050b0| 6f 75 6e 74 20 3d 3d 20 | 32 20 26 26 20 21 6d 6f |ount == |2 && !mo|
|000050c0| 64 69 66 4b 65 79 20 26 | 26 0d 0a 20 20 20 20 20 |difKey &|&.. |
|000050d0| 20 20 20 20 20 20 20 20 | 20 74 68 69 73 2e 74 72 | | this.tr|
|000050e0| 65 65 42 6f 78 4f 62 6a | 65 63 74 2e 76 69 65 77 |eeBoxObj|ect.view|
|000050f0| 2e 69 73 43 6f 6e 74 61 | 69 6e 65 72 28 72 6f 77 |.isConta|iner(row|
|00005100| 29 29 0d 0a 20 20 20 20 | 20 20 20 20 20 20 20 20 |)).. | |
|00005110| 72 65 74 75 72 6e 3b 0d | 0a 0d 0a 20 20 20 20 20 |return;.|... |
|00005120| 20 20 20 20 20 69 66 20 | 28 74 68 69 73 2e 63 6c | if |(this.cl|
|00005130| 69 63 6b 43 6f 75 6e 74 | 20 3d 3d 20 32 20 26 26 |ickCount| == 2 &&|
|00005140| 20 6d 6f 64 69 66 4b 65 | 79 29 20 7b 0d 0a 20 20 | modifKe|y) {.. |
|00005150| 20 20 20 20 20 20 20 20 | 20 20 74 68 69 73 2e 74 | | this.t|
|00005160| 72 65 65 42 6f 78 4f 62 | 6a 65 63 74 2e 73 65 6c |reeBoxOb|ject.sel|
|00005170| 65 63 74 69 6f 6e 2e 73 | 65 6c 65 63 74 28 72 6f |ection.s|elect(ro|
|00005180| 77 29 3b 0d 0a 20 20 20 | 20 20 20 20 20 20 20 20 |w);.. | |
|00005190| 20 74 68 69 73 2e 5f 73 | 65 6c 65 63 74 69 6f 6e | this._s|election|
|000051a0| 20 3d 20 74 68 69 73 2e | 67 65 74 54 72 65 65 53 | = this.|getTreeS|
|000051b0| 65 6c 65 63 74 69 6f 6e | 28 29 3b 0d 0a 20 20 20 |election|();.. |
|000051c0| 20 20 20 20 20 20 20 7d | 0d 0a 20 20 20 20 20 20 | }|.. |
|000051d0| 20 20 20 20 76 61 72 20 | 73 65 6c 65 63 74 69 6f | var |selectio|
|000051e0| 6e 20 3d 20 74 68 69 73 | 2e 5f 73 65 6c 65 63 74 |n = this|._select|
|000051f0| 69 6f 6e 3b 0d 0a 0d 0a | 20 20 20 20 20 20 20 20 |ion;....| |
|00005200| 20 20 69 66 20 28 73 65 | 6c 65 63 74 69 6f 6e 2e | if (se|lection.|
|00005210| 69 73 43 6f 6e 74 61 69 | 6e 65 72 5b 30 5d 29 20 |isContai|ner[0]) |
|00005220| 7b 0d 0a 20 20 20 20 20 | 20 20 20 20 20 20 20 69 |{.. | i|
|00005230| 66 20 28 74 68 69 73 2e | 63 6c 69 63 6b 43 6f 75 |f (this.|clickCou|
|00005240| 6e 74 20 3d 3d 20 31 20 | 26 26 20 21 6d 6f 64 69 |nt == 1 |&& !modi|
|00005250| 66 4b 65 79 29 20 7b 0d | 0a 20 20 20 20 20 20 20 |fKey) {.|. |
|00005260| 20 20 20 20 20 20 20 74 | 68 69 73 2e 74 72 65 65 | t|his.tree|
|00005270| 42 6f 78 4f 62 6a 65 63 | 74 2e 76 69 65 77 2e 74 |BoxObjec|t.view.t|
|00005280| 6f 67 67 6c 65 4f 70 65 | 6e 53 74 61 74 65 28 72 |oggleOpe|nState(r|
|00005290| 6f 77 29 3b 0d 0a 20 20 | 20 20 20 20 20 20 20 20 |ow);.. | |
|000052a0| 20 20 20 20 2f 2f 58 58 | 58 70 63 68 3a 20 62 72 | //XX|Xpch: br|
|000052b0| 6f 6b 65 6e 20 73 69 6e | 63 65 20 77 65 20 68 61 |oken sin|ce we ha|
|000052c0| 76 65 20 73 69 6e 67 6c | 65 20 49 44 73 0d 0a 20 |ve singl|e IDs.. |
|000052d0| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 2f 2f 69 | | //i|
|000052e0| 66 20 28 73 65 6c 65 63 | 74 69 6f 6e 2e 70 72 6f |f (selec|tion.pro|
|000052f0| 74 6f 63 6f 6c 5b 30 5d | 20 21 3d 20 22 66 69 6c |tocol[0]| != "fil|
|00005300| 65 22 29 0d 0a 20 20 20 | 20 20 20 20 20 20 20 20 |e").. | |
|00005310| 20 20 20 20 20 72 65 74 | 75 72 6e 3b 0d 0a 20 20 | ret|urn;.. |
|00005320| 20 20 20 20 20 20 20 20 | 20 20 7d 0d 0a 20 20 20 | | }.. |
|00005330| 20 20 20 20 20 20 20 7d | 0d 0a 20 20 20 20 20 20 | }|.. |
|00005340| 20 20 20 20 76 61 72 20 | 62 72 6f 77 73 65 72 54 | var |browserT|
|00005350| 61 72 67 65 74 20 3d 20 | 77 68 65 72 65 54 6f 4f |arget = |whereToO|
|00005360| 70 65 6e 4c 69 6e 6b 28 | 61 45 76 65 6e 74 29 3b |penLink(|aEvent);|
|00005370| 0d 0a 20 20 20 20 20 20 | 20 20 20 20 42 6f 6f 6b |.. | Book|
|00005380| 6d 61 72 6b 73 43 6f 6d | 6d 61 6e 64 2e 6f 70 65 |marksCom|mand.ope|
|00005390| 6e 42 6f 6f 6b 6d 61 72 | 6b 28 73 65 6c 65 63 74 |nBookmar|k(select|
|000053a0| 69 6f 6e 2c 20 62 72 6f | 77 73 65 72 54 61 72 67 |ion, bro|wserTarg|
|000053b0| 65 74 2c 20 74 68 69 73 | 2e 64 62 29 3b 0d 0a 20 |et, this|.db);.. |
|000053c0| 20 20 20 20 20 20 20 5d | 5d 3e 3c 2f 62 6f 64 79 | ]|]></body|
|000053d0| 3e 0d 0a 20 20 20 20 20 | 20 3c 2f 6d 65 74 68 6f |>.. | </metho|
|000053e0| 64 3e 0d 0a 0d 0a 20 20 | 20 20 20 20 3c 6d 65 74 |d>.... | <met|
|000053f0| 68 6f 64 20 6e 61 6d 65 | 3d 22 6f 70 65 6e 49 74 |hod name|="openIt|
|00005400| 65 6d 4b 65 79 22 3e 0d | 0a 20 20 20 20 20 20 20 |emKey">.|. |
|00005410| 20 3c 62 6f 64 79 3e 3c | 21 5b 43 44 41 54 41 5b | <body><|![CDATA[|
|00005420| 0d 0a 20 20 20 20 20 20 | 20 20 20 20 69 66 20 28 |.. | if (|
|00005430| 74 68 69 73 2e 5f 73 65 | 6c 65 63 74 69 6f 6e 2e |this._se|lection.|
|00005440| 6c 65 6e 67 74 68 20 21 | 3d 20 31 29 20 7b 0d 0a |length !|= 1) {..|
|00005450| 20 20 20 20 20 20 20 20 | 20 20 20 20 72 65 74 75 | | retu|
|00005460| 72 6e 3b 0d 0a 20 20 20 | 20 20 20 20 20 20 20 7d |rn;.. | }|
|00005470| 0d 0a 20 20 20 20 20 20 | 20 20 20 20 69 66 20 28 |.. | if (|
|00005480| 21 74 68 69 73 2e 5f 73 | 65 6c 65 63 74 69 6f 6e |!this._s|election|
|00005490| 2e 69 73 43 6f 6e 74 61 | 69 6e 65 72 5b 30 5d 29 |.isConta|iner[0])|
|000054a0| 0d 0a 20 20 20 20 20 20 | 20 20 20 20 20 20 42 6f |.. | Bo|
|000054b0| 6f 6b 6d 61 72 6b 73 43 | 6f 6d 6d 61 6e 64 2e 6f |okmarksC|ommand.o|
|000054c0| 70 65 6e 42 6f 6f 6b 6d | 61 72 6b 28 74 68 69 73 |penBookm|ark(this|
|000054d0| 2e 5f 73 65 6c 65 63 74 | 69 6f 6e 2c 20 22 63 75 |._select|ion, "cu|
|000054e0| 72 72 65 6e 74 22 2c 20 | 74 68 69 73 2e 64 62 29 |rrent", |this.db)|
|000054f0| 0d 0a 20 20 20 20 20 20 | 20 20 5d 5d 3e 3c 2f 62 |.. | ]]></b|
|00005500| 6f 64 79 3e 0d 0a 20 20 | 20 20 20 20 3c 2f 6d 65 |ody>.. | </me|
|00005510| 74 68 6f 64 3e 0d 0a 0d | 0a 20 20 20 20 20 20 3c |thod>...|. <|
|00005520| 6d 65 74 68 6f 64 20 6e | 61 6d 65 3d 22 73 65 61 |method n|ame="sea|
|00005530| 72 63 68 42 6f 6f 6b 6d | 61 72 6b 73 22 3e 0d 0a |rchBookm|arks">..|
|00005540| 20 20 20 20 20 20 3c 70 | 61 72 61 6d 65 74 65 72 | <p|arameter|
|00005550| 20 6e 61 6d 65 3d 22 61 | 49 6e 70 75 74 22 2f 3e | name="a|Input"/>|
|00005560| 0d 0a 20 20 20 20 20 20 | 20 20 3c 62 6f 64 79 3e |.. | <body>|
|00005570| 3c 21 5b 43 44 41 54 41 | 5b 0d 0a 20 20 20 20 20 |<![CDATA|[.. |
|00005580| 20 20 20 20 20 69 66 20 | 28 21 61 49 6e 70 75 74 | if |(!aInput|
|00005590| 29 0d 0a 20 20 20 20 20 | 20 20 20 20 20 20 20 74 |).. | t|
|000055a0| 68 69 73 2e 74 72 65 65 | 2e 73 65 74 41 74 74 72 |his.tree|.setAttr|
|000055b0| 69 62 75 74 65 28 22 72 | 65 66 22 2c 20 74 68 69 |ibute("r|ef", thi|
|000055c0| 73 2e 6f 72 69 67 69 6e | 61 6c 52 65 66 29 3b 0d |s.origin|alRef);.|
|000055d0| 0a 20 20 20 20 20 20 20 | 20 20 20 65 6c 73 65 20 |. | else |
|000055e0| 7b 0d 0a 20 20 20 20 20 | 20 20 20 20 20 20 20 69 |{.. | i|
|000055f0| 66 20 28 21 74 68 69 73 | 2e 6f 72 69 67 69 6e 61 |f (!this|.origina|
|00005600| 6c 52 65 66 29 20 7b 0d | 0a 20 20 20 20 20 20 20 |lRef) {.|. |
|00005610| 20 20 20 20 20 20 20 74 | 68 69 73 2e 6f 72 69 67 | t|his.orig|
|00005620| 69 6e 61 6c 52 65 66 20 | 3d 20 74 68 69 73 2e 74 |inalRef |= this.t|
|00005630| 72 65 65 2e 67 65 74 41 | 74 74 72 69 62 75 74 65 |ree.getA|ttribute|
|00005640| 28 22 72 65 66 22 29 3b | 0d 0a 20 20 20 20 20 20 |("ref");|.. |
|00005650| 20 20 20 20 20 20 7d 0d | 0a 20 20 20 20 20 20 20 | }.|. |
|00005660| 20 20 20 20 20 74 68 69 | 73 2e 74 72 65 65 2e 73 | thi|s.tree.s|
|00005670| 65 74 41 74 74 72 69 62 | 75 74 65 28 22 72 65 66 |etAttrib|ute("ref|
|00005680| 22 2c 0d 0a 20 20 20 20 | 20 20 20 20 20 20 20 20 |",.. | |
|00005690| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 20 20 20 | | |
|000056a0| 20 20 20 20 20 20 20 22 | 66 69 6e 64 3a 64 61 74 | "|find:dat|
|000056b0| 61 73 6f 75 72 63 65 3d | 72 64 66 3a 62 6f 6f 6b |asource=|rdf:book|
|000056c0| 6d 61 72 6b 73 26 6d 61 | 74 63 68 3d 68 74 74 70 |marks&ma|tch=http|
|000056d0| 3a 2f 2f 68 6f 6d 65 2e | 6e 65 74 73 63 61 70 65 |://home.|netscape|
|000056e0| 2e 63 6f 6d 2f 4e 43 2d | 72 64 66 23 4e 61 6d 65 |.com/NC-|rdf#Name|
|000056f0| 26 6d 65 74 68 6f 64 3d | 63 6f 6e 74 61 69 6e 73 |&method=|contains|
|00005700| 26 74 65 78 74 3d 22 20 | 2b 20 65 6e 63 6f 64 65 |&text=" |+ encode|
|00005710| 55 52 49 43 6f 6d 70 6f | 6e 65 6e 74 28 61 49 6e |URICompo|nent(aIn|
|00005720| 70 75 74 29 29 3b 0d 0a | 20 20 20 20 20 20 20 20 |put));..| |
|00005730| 20 20 7d 0d 0a 20 20 20 | 20 20 20 20 20 5d 5d 3e | }.. | ]]>|
|00005740| 3c 2f 62 6f 64 79 3e 0d | 0a 20 20 20 20 20 20 3c |</body>.|. <|
|00005750| 2f 6d 65 74 68 6f 64 3e | 0d 0a 0d 0a 20 20 20 20 |/method>|.... |
|00005760| 20 20 3c 21 2d 2d 20 6f | 62 73 65 72 76 65 72 20 | <!-- o|bserver |
|00005770| 2d 2d 3e 0d 0a 20 20 20 | 20 20 20 3c 66 69 65 6c |-->.. | <fiel|
|00005780| 64 20 6e 61 6d 65 3d 22 | 44 4e 44 4f 62 73 65 72 |d name="|DNDObser|
|00005790| 76 65 72 22 20 72 65 61 | 64 6f 6e 6c 79 3d 22 74 |ver" rea|donly="t|
|000057a0| 72 75 65 22 3e 3c 21 5b | 43 44 41 54 41 5b 0d 0a |rue"><![|CDATA[..|
|000057b0| 20 20 20 20 20 20 28 7b | 0d 0a 20 20 20 20 20 20 | ({|.. |
|000057c0| 20 20 6d 4f 75 74 65 72 | 3a 20 74 68 69 73 2c 0d | mOuter|: this,.|
|000057d0| 0a 20 20 20 20 20 20 20 | 20 6f 6e 44 72 61 67 53 |. | onDragS|
|000057e0| 74 61 72 74 3a 20 66 75 | 6e 63 74 69 6f 6e 20 28 |tart: fu|nction (|
|000057f0| 61 45 76 65 6e 74 2c 20 | 61 58 66 65 72 44 61 74 |aEvent, |aXferDat|
|00005800| 61 2c 20 61 44 72 61 67 | 41 63 74 69 6f 6e 29 0d |a, aDrag|Action).|
|00005810| 0a 20 20 20 20 20 20 20 | 20 7b 0d 0a 20 20 20 20 |. | {.. |
|00005820| 20 20 20 20 20 20 69 66 | 20 28 74 68 69 73 2e 6d | if| (this.m|
|00005830| 4f 75 74 65 72 2e 74 72 | 65 65 2e 67 65 74 41 74 |Outer.tr|ee.getAt|
|00005840| 74 72 69 62 75 74 65 28 | 22 73 6f 72 74 41 63 74 |tribute(|"sortAct|
|00005850| 69 76 65 22 29 20 3d 3d | 20 22 74 72 75 65 22 29 |ive") ==| "true")|
|00005860| 0d 0a 20 20 20 20 20 20 | 20 20 20 20 20 20 74 68 |.. | th|
|00005870| 72 6f 77 20 43 6f 6d 70 | 6f 6e 65 6e 74 73 2e 72 |row Comp|onents.r|
|00005880| 65 73 75 6c 74 73 2e 4e | 53 5f 4f 4b 3b 20 0d 0a |esults.N|S_OK; ..|
|00005890| 20 20 20 20 20 20 20 20 | 20 20 76 61 72 20 73 65 | | var se|
|000058a0| 6c 65 63 74 69 6f 6e 20 | 3d 20 74 68 69 73 2e 6d |lection |= this.m|
|000058b0| 4f 75 74 65 72 2e 5f 73 | 65 6c 65 63 74 69 6f 6e |Outer._s|election|
|000058c0| 3b 0d 0a 20 20 20 20 20 | 20 20 20 20 20 61 58 66 |;.. | aXf|
|000058d0| 65 72 44 61 74 61 2e 64 | 61 74 61 20 3d 20 42 6f |erData.d|ata = Bo|
|000058e0| 6f 6b 6d 61 72 6b 73 55 | 74 69 6c 73 2e 67 65 74 |okmarksU|tils.get|
|000058f0| 58 66 65 72 44 61 74 61 | 46 72 6f 6d 53 65 6c 65 |XferData|FromSele|
|00005900| 63 74 69 6f 6e 28 73 65 | 6c 65 63 74 69 6f 6e 29 |ction(se|lection)|
|00005910| 3b 0d 0a 20 20 20 20 20 | 20 20 20 20 20 69 66 20 |;.. | if |
|00005920| 28 61 45 76 65 6e 74 2e | 63 74 72 6c 4b 65 79 29 |(aEvent.|ctrlKey)|
|00005930| 0d 0a 20 20 20 20 20 20 | 20 20 20 20 20 20 61 44 |.. | aD|
|00005940| 72 61 67 41 63 74 69 6f | 6e 2e 61 63 74 69 6f 6e |ragActio|n.action|
|00005950| 20 3d 20 6b 44 53 49 49 | 44 2e 44 52 41 47 44 52 | = kDSII|D.DRAGDR|
|00005960| 4f 50 5f 41 43 54 49 4f | 4e 5f 43 4f 50 59 3b 0d |OP_ACTIO|N_COPY;.|
|00005970| 0a 20 20 20 20 20 20 20 | 20 7d 0d 0a 20 20 20 20 |. | }.. |
|00005980| 20 20 7d 29 0d 0a 20 20 | 20 20 20 20 5d 5d 3e 3c | }).. | ]]><|
|00005990| 2f 66 69 65 6c 64 3e 20 | 20 20 20 20 20 0d 0a 20 |/field> | .. |
|000059a0| 20 20 20 20 20 20 20 0d | 0a 20 20 20 20 20 20 3c | .|. <|
|000059b0| 21 2d 2d 20 6e 73 49 43 | 6f 6e 74 72 6f 6c 6c 65 |!-- nsIC|ontrolle|
|000059c0| 72 20 2d 2d 3e 0d 0a 20 | 20 20 20 20 20 3c 66 69 |r -->.. | <fi|
|000059d0| 65 6c 64 20 6e 61 6d 65 | 3d 22 63 6f 6e 74 72 6f |eld name|="contro|
|000059e0| 6c 6c 65 72 22 20 72 65 | 61 64 6f 6e 6c 79 3d 22 |ller" re|adonly="|
|000059f0| 74 72 75 65 22 3e 3c 21 | 5b 43 44 41 54 41 5b 0d |true"><!|[CDATA[.|
|00005a00| 0a 20 20 20 20 20 20 28 | 7b 0d 0a 20 20 20 20 20 |. (|{.. |
|00005a10| 20 20 20 6d 4f 75 74 65 | 72 3a 20 74 68 69 73 2c | mOute|r: this,|
|00005a20| 0d 0a 20 20 20 20 20 20 | 20 20 0d 0a 20 20 20 20 |.. | .. |
|00005a30| 20 20 20 20 73 75 70 70 | 6f 72 74 73 43 6f 6d 6d | supp|ortsComm|
|00005a40| 61 6e 64 3a 20 42 6f 6f | 6b 6d 61 72 6b 73 43 6f |and: Boo|kmarksCo|
|00005a50| 6e 74 72 6f 6c 6c 65 72 | 2e 73 75 70 70 6f 72 74 |ntroller|.support|
|00005a60| 73 43 6f 6d 6d 61 6e 64 | 2c 0d 0a 20 20 20 20 20 |sCommand|,.. |
|00005a70| 20 20 20 0d 0a 20 20 20 | 20 20 20 20 20 69 73 43 | .. | isC|
|00005a80| 6f 6d 6d 61 6e 64 45 6e | 61 62 6c 65 64 3a 20 66 |ommandEn|abled: f|
|00005a90| 75 6e 63 74 69 6f 6e 20 | 28 61 43 6f 6d 6d 61 6e |unction |(aComman|
|00005aa0| 64 29 0d 0a 20 20 20 20 | 20 20 20 20 7b 0d 0a 20 |d).. | {.. |
|00005ab0| 20 20 20 20 20 20 20 20 | 20 2f 2f 20 77 61 72 6e | | // warn|
|00005ac0| 69 6e 67 3a 20 74 68 69 | 73 20 69 73 20 6e 6f 74 |ing: thi|s is not|
|00005ad0| 20 74 68 65 20 63 61 6c | 6c 65 64 20 66 75 6e 63 | the cal|led func|
|00005ae0| 74 69 6f 6e 20 69 6e 20 | 42 6f 6f 6b 6d 61 72 6b |tion in |Bookmark|
|00005af0| 73 43 6f 6e 74 72 6f 6c | 6c 65 72 2e 6f 6e 43 6f |sControl|ler.onCo|
|00005b00| 6d 6d 61 6e 64 55 70 64 | 61 74 65 0d 0a 20 20 20 |mmandUpd|ate.. |
|00005b10| 20 20 20 20 20 20 20 76 | 61 72 20 73 65 6c 65 63 | v|ar selec|
|00005b20| 74 69 6f 6e 20 3d 20 74 | 68 69 73 2e 6d 4f 75 74 |tion = t|his.mOut|
|00005b30| 65 72 2e 5f 73 65 6c 65 | 63 74 69 6f 6e 3b 0d 0a |er._sele|ction;..|
|00005b40| 20 20 20 20 20 20 20 20 | 20 20 76 61 72 20 74 61 | | var ta|
|00005b50| 72 67 65 74 20 20 20 20 | 3d 20 74 68 69 73 2e 6d |rget |= this.m|
|00005b60| 4f 75 74 65 72 2e 5f 74 | 61 72 67 65 74 3b 0d 0a |Outer._t|arget;..|
|00005b70| 20 20 20 20 20 20 20 20 | 20 20 72 65 74 75 72 6e | | return|
|00005b80| 20 42 6f 6f 6b 6d 61 72 | 6b 73 43 6f 6e 74 72 6f | Bookmar|ksContro|
|00005b90| 6c 6c 65 72 2e 69 73 43 | 6f 6d 6d 61 6e 64 45 6e |ller.isC|ommandEn|
|00005ba0| 61 62 6c 65 64 28 61 43 | 6f 6d 6d 61 6e 64 2c 20 |abled(aC|ommand, |
|00005bb0| 73 65 6c 65 63 74 69 6f | 6e 2c 20 74 61 72 67 65 |selectio|n, targe|
|00005bc0| 74 29 0d 0a 20 20 20 20 | 20 20 20 20 7d 2c 0d 0a |t).. | },..|
|00005bd0| 0d 0a 20 20 20 20 20 20 | 20 20 64 6f 43 6f 6d 6d |.. | doComm|
|00005be0| 61 6e 64 3a 20 66 75 6e | 63 74 69 6f 6e 20 28 61 |and: fun|ction (a|
|00005bf0| 43 6f 6d 6d 61 6e 64 29 | 0d 0a 20 20 20 20 20 20 |Command)|.. |
|00005c00| 20 20 7b 0d 0a 20 20 20 | 20 20 20 20 20 20 20 76 | {.. | v|
|00005c10| 61 72 20 73 65 6c 65 63 | 74 69 6f 6e 20 3d 20 74 |ar selec|tion = t|
|00005c20| 68 69 73 2e 6d 4f 75 74 | 65 72 2e 5f 73 65 6c 65 |his.mOut|er._sele|
|00005c30| 63 74 69 6f 6e 3b 0d 0a | 20 20 20 20 20 20 20 20 |ction;..| |
|00005c40| 20 20 76 61 72 20 74 61 | 72 67 65 74 20 20 20 20 | var ta|rget |
|00005c50| 3d 20 74 68 69 73 2e 6d | 4f 75 74 65 72 2e 5f 74 |= this.m|Outer._t|
|00005c60| 61 72 67 65 74 3b 0d 0a | 20 20 20 20 20 20 20 20 |arget;..| |
|00005c70| 20 20 74 68 69 73 2e 6d | 4f 75 74 65 72 2e 74 72 | this.m|Outer.tr|
|00005c80| 65 65 42 6f 78 4f 62 6a | 65 63 74 2e 73 65 6c 65 |eeBoxObj|ect.sele|
|00005c90| 63 74 69 6f 6e 2e 73 65 | 6c 65 63 74 45 76 65 6e |ction.se|lectEven|
|00005ca0| 74 73 53 75 70 70 72 65 | 73 73 65 64 20 3d 20 74 |tsSuppre|ssed = t|
|00005cb0| 72 75 65 3b 0d 0a 20 20 | 20 20 20 20 20 20 20 20 |rue;.. | |
|00005cc0| 74 68 69 73 2e 6d 4f 75 | 74 65 72 2e 5f 69 74 65 |this.mOu|ter._ite|
|00005cd0| 6d 54 6f 42 65 54 6f 67 | 67 6c 65 64 20 3d 20 5b |mToBeTog|gled = [|
|00005ce0| 5d 3b 0d 0a 20 20 20 20 | 20 20 20 20 20 20 0d 0a |];.. | ..|
|00005cf0| 20 20 20 20 20 20 20 20 | 20 20 73 77 69 74 63 68 | | switch|
|00005d00| 20 28 61 43 6f 6d 6d 61 | 6e 64 29 20 7b 0d 0a 20 | (aComma|nd) {.. |
|00005d10| 20 20 20 20 20 20 20 20 | 20 63 61 73 65 20 22 63 | | case "c|
|00005d20| 6d 64 5f 73 65 6c 65 63 | 74 41 6c 6c 22 3a 0d 0a |md_selec|tAll":..|
|00005d30| 20 20 20 20 20 20 20 20 | 20 20 20 20 74 68 69 73 | | this|
|00005d40| 2e 6d 4f 75 74 65 72 2e | 74 72 65 65 42 6f 78 4f |.mOuter.|treeBoxO|
|00005d50| 62 6a 65 63 74 2e 73 65 | 6c 65 63 74 69 6f 6e 2e |bject.se|lection.|
|00005d60| 73 65 6c 65 63 74 41 6c | 6c 28 29 3b 0d 0a 20 20 |selectAl|l();.. |
|00005d70| 20 20 20 20 20 20 20 20 | 20 20 62 72 65 61 6b 3b | | break;|
|00005d80| 0d 0a 20 20 20 20 20 20 | 20 20 20 20 63 61 73 65 |.. | case|
|00005d90| 20 22 63 6d 64 5f 62 6d | 5f 65 78 70 61 6e 64 66 | "cmd_bm|_expandf|
|00005da0| 6f 6c 64 65 72 22 3a 0d | 0a 20 20 20 20 20 20 20 |older":.|. |
|00005db0| 20 20 20 20 20 74 68 69 | 73 2e 6d 4f 75 74 65 72 | thi|s.mOuter|
|00005dc0| 2e 74 72 65 65 42 6f 78 | 4f 62 6a 65 63 74 2e 76 |.treeBox|Object.v|
|00005dd0| 69 65 77 2e 74 6f 67 67 | 6c 65 4f 70 65 6e 53 74 |iew.togg|leOpenSt|
|00005de0| 61 74 65 28 74 68 69 73 | 2e 6d 4f 75 74 65 72 2e |ate(this|.mOuter.|
|00005df0| 63 75 72 72 65 6e 74 49 | 6e 64 65 78 29 3b 0d 0a |currentI|ndex);..|
|00005e00| 20 20 20 20 20 20 20 20 | 20 20 20 20 62 72 65 61 | | brea|
|00005e10| 6b 3b 0d 0a 20 20 20 20 | 20 20 20 20 20 20 64 65 |k;.. | de|
|00005e20| 66 61 75 6c 74 3a 0d 0a | 20 20 20 20 20 20 20 20 |fault:..| |
|00005e30| 20 20 20 20 74 68 69 73 | 2e 6d 4f 75 74 65 72 2e | this|.mOuter.|
|00005e40| 73 61 76 65 53 65 6c 65 | 63 74 69 6f 6e 28 29 3b |saveSele|ction();|
|00005e50| 0d 0a 20 20 20 20 20 20 | 20 20 20 20 20 20 42 6f |.. | Bo|
|00005e60| 6f 6b 6d 61 72 6b 73 43 | 6f 6e 74 72 6f 6c 6c 65 |okmarksC|ontrolle|
|00005e70| 72 2e 64 6f 43 6f 6d 6d | 61 6e 64 28 61 43 6f 6d |r.doComm|and(aCom|
|00005e80| 6d 61 6e 64 2c 20 73 65 | 6c 65 63 74 69 6f 6e 2c |mand, se|lection,|
|00005e90| 20 74 61 72 67 65 74 29 | 3b 0d 0a 20 20 20 20 20 | target)|;.. |
|00005ea0| 20 20 20 20 20 20 20 74 | 68 69 73 2e 6d 4f 75 74 | t|his.mOut|
|00005eb0| 65 72 2e 72 65 73 74 6f | 72 65 53 65 6c 65 63 74 |er.resto|reSelect|
|00005ec0| 69 6f 6e 28 61 43 6f 6d | 6d 61 6e 64 29 3b 0d 0a |ion(aCom|mand);..|
|00005ed0| 20 20 20 20 20 20 20 20 | 20 20 7d 0d 0a 20 20 20 | | }.. |
|00005ee0| 20 20 20 20 20 20 20 74 | 68 69 73 2e 6d 4f 75 74 | t|his.mOut|
|00005ef0| 65 72 2e 74 72 65 65 42 | 6f 78 4f 62 6a 65 63 74 |er.treeB|oxObject|
|00005f00| 2e 73 65 6c 65 63 74 69 | 6f 6e 2e 73 65 6c 65 63 |.selecti|on.selec|
|00005f10| 74 45 76 65 6e 74 73 53 | 75 70 70 72 65 73 73 65 |tEventsS|uppresse|
|00005f20| 64 20 3d 20 66 61 6c 73 | 65 3b 0d 0a 20 20 20 20 |d = fals|e;.. |
|00005f30| 20 20 20 20 7d 0d 0a 20 | 20 20 20 20 20 7d 29 0d | }.. | }).|
|00005f40| 0a 20 20 20 20 20 20 5d | 5d 3e 3c 2f 66 69 65 6c |. ]|]></fiel|
|00005f50| 64 3e 0d 0a 0d 0a 20 20 | 20 20 20 20 3c 6d 65 74 |d>.... | <met|
|00005f60| 68 6f 64 20 6e 61 6d 65 | 3d 22 6f 6e 43 6f 6d 6d |hod name|="onComm|
|00005f70| 61 6e 64 55 70 64 61 74 | 65 22 3e 0d 0a 20 20 20 |andUpdat|e">.. |
|00005f80| 20 20 20 20 20 3c 62 6f | 64 79 3e 3c 21 5b 43 44 | <bo|dy><![CD|
|00005f90| 41 54 41 5b 0d 0a 20 20 | 20 20 20 20 20 20 20 20 |ATA[.. | |
|00005fa0| 76 61 72 20 73 65 6c 65 | 63 74 69 6f 6e 20 3d 20 |var sele|ction = |
|00005fb0| 74 68 69 73 2e 5f 73 65 | 6c 65 63 74 69 6f 6e 3b |this._se|lection;|
|00005fc0| 0d 0a 20 20 20 20 20 20 | 20 20 20 20 76 61 72 20 |.. | var |
|00005fd0| 74 61 72 67 65 74 20 20 | 20 20 3d 20 74 68 69 73 |target | = this|
|00005fe0| 2e 5f 74 61 72 67 65 74 | 3b 0d 0a 20 20 20 20 20 |._target|;.. |
|00005ff0| 20 20 20 20 20 42 6f 6f | 6b 6d 61 72 6b 73 43 6f | Boo|kmarksCo|
|00006000| 6e 74 72 6f 6c 6c 65 72 | 2e 6f 6e 43 6f 6d 6d 61 |ntroller|.onComma|
|00006010| 6e 64 55 70 64 61 74 65 | 28 73 65 6c 65 63 74 69 |ndUpdate|(selecti|
|00006020| 6f 6e 2c 20 74 61 72 67 | 65 74 29 3b 0d 0a 20 20 |on, targ|et);.. |
|00006030| 20 20 20 20 20 20 5d 5d | 3e 3c 2f 62 6f 64 79 3e | ]]|></body>|
|00006040| 0d 0a 20 20 20 20 20 20 | 3c 2f 6d 65 74 68 6f 64 |.. |</method|
|00006050| 3e 0d 0a 0d 0a 20 20 20 | 20 20 20 3c 6d 65 74 68 |>.... | <meth|
|00006060| 6f 64 20 6e 61 6d 65 3d | 22 73 65 6c 65 63 74 69 |od name=|"selecti|
|00006070| 6f 6e 43 68 61 6e 67 65 | 64 22 3e 0d 0a 20 20 20 |onChange|d">.. |
|00006080| 20 20 20 20 20 3c 70 61 | 72 61 6d 65 74 65 72 20 | <pa|rameter |
|00006090| 6e 61 6d 65 3d 22 61 45 | 76 65 6e 74 22 2f 3e 0d |name="aE|vent"/>.|
|000060a0| 0a 20 20 20 20 20 20 20 | 20 3c 62 6f 64 79 3e 3c |. | <body><|
|000060b0| 21 5b 43 44 41 54 41 5b | 0d 0a 20 20 20 20 20 20 |![CDATA[|.. |
|000060c0| 20 20 5d 5d 3e 3c 2f 62 | 6f 64 79 3e 0d 0a 20 20 | ]]></b|ody>.. |
|000060d0| 20 20 20 20 3c 2f 6d 65 | 74 68 6f 64 3e 0d 0a 0d | </me|thod>...|
|000060e0| 0a 20 20 20 20 20 20 3c | 21 2d 2d 20 6e 73 49 58 |. <|!-- nsIX|
|000060f0| 55 4c 54 72 65 65 42 75 | 69 6c 64 65 72 4f 62 73 |ULTreeBu|ilderObs|
|00006100| 65 72 76 65 72 20 2d 2d | 3e 0d 0a 20 20 20 20 20 |erver --|>.. |
|00006110| 20 3c 66 69 65 6c 64 20 | 6e 61 6d 65 3d 22 62 75 | <field |name="bu|
|00006120| 69 6c 64 65 72 4f 62 73 | 65 72 76 65 72 22 3e 3c |ilderObs|erver"><|
|00006130| 21 5b 43 44 41 54 41 5b | 0d 0a 20 20 20 20 20 20 |![CDATA[|.. |
|00006140| 28 7b 0d 0a 20 20 20 20 | 20 20 20 20 6d 4f 75 74 |({.. | mOut|
|00006150| 65 72 3a 20 74 68 69 73 | 2c 0d 0a 20 20 20 20 20 |er: this|,.. |
|00006160| 20 20 20 63 61 6e 44 72 | 6f 70 4f 6e 3a 20 66 75 | canDr|opOn: fu|
|00006170| 6e 63 74 69 6f 6e 28 69 | 6e 64 65 78 29 0d 0a 20 |nction(i|ndex).. |
|00006180| 20 20 20 20 20 20 20 7b | 0d 0a 20 20 20 20 20 20 | {|.. |
|00006190| 20 20 20 20 76 61 72 20 | 64 72 61 67 53 65 73 73 | var |dragSess|
|000061a0| 69 6f 6e 20 3d 20 44 53 | 2e 67 65 74 43 75 72 72 |ion = DS|.getCurr|
|000061b0| 65 6e 74 53 65 73 73 69 | 6f 6e 28 29 3b 0d 0a 20 |entSessi|on();.. |
|000061c0| 20 20 20 20 20 20 20 20 | 20 69 66 20 28 21 64 72 | | if (!dr|
|000061d0| 61 67 53 65 73 73 69 6f | 6e 29 0d 0a 20 20 20 20 |agSessio|n).. |
|000061e0| 20 20 20 20 20 20 20 20 | 72 65 74 75 72 6e 20 66 | |return f|
|000061f0| 61 6c 73 65 3b 0d 0a 20 | 20 20 20 20 20 20 20 20 |alse;.. | |
|00006200| 20 76 61 72 20 73 65 6c | 65 63 74 69 6f 6e 20 3d | var sel|ection =|
|00006210| 20 42 6f 6f 6b 6d 61 72 | 6b 73 55 74 69 6c 73 2e | Bookmar|ksUtils.|
|00006220| 67 65 74 53 65 6c 65 63 | 74 69 6f 6e 46 72 6f 6d |getSelec|tionFrom|
|00006230| 58 66 65 72 44 61 74 61 | 28 64 72 61 67 53 65 73 |XferData|(dragSes|
|00006240| 73 69 6f 6e 29 3b 0d 0a | 20 20 20 20 20 20 20 20 |sion);..| |
|00006250| 20 20 72 65 74 75 72 6e | 20 21 73 65 6c 65 63 74 | return| !select|
|00006260| 69 6f 6e 2e 63 6f 6e 74 | 61 69 6e 73 49 6d 6d 75 |ion.cont|ainsImmu|
|00006270| 74 61 62 6c 65 3b 0d 0a | 20 20 20 20 20 20 20 20 |table;..| |
|00006280| 7d 2c 0d 0a 20 20 20 20 | 20 20 20 20 63 61 6e 44 |},.. | canD|
|00006290| 72 6f 70 42 65 66 6f 72 | 65 41 66 74 65 72 3a 20 |ropBefor|eAfter: |
|000062a0| 66 75 6e 63 74 69 6f 6e | 28 69 6e 64 65 78 2c 20 |function|(index, |
|000062b0| 62 65 66 6f 72 65 29 0d | 0a 20 20 20 20 20 20 20 |before).|. |
|000062c0| 20 7b 0d 0a 20 20 20 20 | 20 20 20 20 20 20 76 61 | {.. | va|
|000062d0| 72 20 64 72 61 67 53 65 | 73 73 69 6f 6e 20 3d 20 |r dragSe|ssion = |
|000062e0| 44 53 2e 67 65 74 43 75 | 72 72 65 6e 74 53 65 73 |DS.getCu|rrentSes|
|000062f0| 73 69 6f 6e 28 29 3b 0d | 0a 20 20 20 20 20 20 20 |sion();.|. |
|00006300| 20 20 20 69 66 20 28 21 | 64 72 61 67 53 65 73 73 | if (!|dragSess|
|00006310| 69 6f 6e 29 0d 0a 20 20 | 20 20 20 20 20 20 20 20 |ion).. | |
|00006320| 20 20 72 65 74 75 72 6e | 20 66 61 6c 73 65 3b 0d | return| false;.|
|00006330| 0a 20 20 20 20 20 20 20 | 20 20 20 76 61 72 20 73 |. | var s|
|00006340| 65 6c 65 63 74 69 6f 6e | 20 3d 20 42 6f 6f 6b 6d |election| = Bookm|
|00006350| 61 72 6b 73 55 74 69 6c | 73 2e 67 65 74 53 65 6c |arksUtil|s.getSel|
|00006360| 65 63 74 69 6f 6e 46 72 | 6f 6d 58 66 65 72 44 61 |ectionFr|omXferDa|
|00006370| 74 61 28 64 72 61 67 53 | 65 73 73 69 6f 6e 29 3b |ta(dragS|ession);|
|00006380| 0d 0a 20 20 20 20 20 20 | 20 20 20 20 69 66 20 28 |.. | if (|
|00006390| 73 65 6c 65 63 74 69 6f | 6e 2e 63 6f 6e 74 61 69 |selectio|n.contai|
|000063a0| 6e 73 49 6d 6d 75 74 61 | 62 6c 65 29 0d 0a 20 20 |nsImmuta|ble).. |
|000063b0| 20 20 20 20 20 20 20 20 | 20 20 72 65 74 75 72 6e | | return|
|000063c0| 20 66 61 6c 73 65 3b 0d | 0a 0d 0a 20 20 20 20 20 | false;.|... |
|000063d0| 20 20 20 20 20 69 66 20 | 28 69 6e 64 65 78 20 21 | if |(index !|
|000063e0| 3d 20 30 29 0d 0a 20 20 | 20 20 20 20 20 20 20 20 |= 0).. | |
|000063f0| 20 20 72 65 74 75 72 6e | 20 74 72 75 65 3b 0d 0a | return| true;..|
+--------+-------------------------+-------------------------+--------+--------+
Only 25.0 KB of data is shown above.